Skip to content
This repository has been archived by the owner on Jan 15, 2023. It is now read-only.

Commit

Permalink
Problem: coverage is not calculated correctly.
Browse files Browse the repository at this point in the history
Solution: add dummy tests to packages w/o tests.
  • Loading branch information
AlekSi committed Dec 11, 2018
1 parent f05ac68 commit 9c3a8d4
Show file tree
Hide file tree
Showing 5 changed files with 55 additions and 1 deletion.
2 changes: 1 addition & 1 deletion .codecov.yml
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
coverage:
range: "75...85"
range: "55...70"
3 changes: 3 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,11 @@ install:

test: install
go build -v -tags gofuzz ./...
go test -v ./tokens
go test -v ./scanner
go test -v ./ast
go test -v ./parser
go test -v ./objects
go test -v ./interpreter
go test -v -covermode=count -coverprofile=cover.out ./...

Expand Down
17 changes: 17 additions & 0 deletions ast/ast_test.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
// Gosh programming language.
// Copyright (c) 2018 Alexey Palazhchenko and contributors.
//
// This Source Code Form is subject to the terms of the Mozilla Public
// License, v. 2.0. If a copy of the MPL was not distributed with this
// file, You can obtain one at http://mozilla.org/MPL/2.0/.

package ast

import (
"testing"
)

// This dummy test exists for correct test coverage calculations.
// Remove it when real tests are added.
func TestDummy(t *testing.T) {
}
17 changes: 17 additions & 0 deletions objects/objects_test.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
// Gosh programming language.
// Copyright (c) 2018 Alexey Palazhchenko and contributors.
//
// This Source Code Form is subject to the terms of the Mozilla Public
// License, v. 2.0. If a copy of the MPL was not distributed with this
// file, You can obtain one at http://mozilla.org/MPL/2.0/.

package objects

import (
"testing"
)

// This dummy test exists for correct test coverage calculations.
// Remove it when real tests are added.
func TestDummy(t *testing.T) {
}
17 changes: 17 additions & 0 deletions tokens/tokens_test.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
// Gosh programming language.
// Copyright (c) 2018 Alexey Palazhchenko and contributors.
//
// This Source Code Form is subject to the terms of the Mozilla Public
// License, v. 2.0. If a copy of the MPL was not distributed with this
// file, You can obtain one at http://mozilla.org/MPL/2.0/.

package tokens

import (
"testing"
)

// This dummy test exists for correct test coverage calculations.
// Remove it when real tests are added.
func TestDummy(t *testing.T) {
}

0 comments on commit 9c3a8d4

Please sign in to comment.