Skip to content

Commit 461418e

Browse files
committed
scripts: Exclude main package from test coverage stat
1 parent 05fcf6b commit 461418e

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

scripts/coverage.sh

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
#!/usr/bin/env bash
22

3-
go test -race -coverpkg=./... -v -coverprofile coverage.out ./...
3+
go test -race -coverpkg=./... -v -coverprofile coverage.out.tmp ./...
4+
cat coverage.out.tmp | grep -v "cmd/aoc-cli" > coverage.out
5+
rm -rf coverage.out.tmp
46
gocov convert coverage.out | gocov report
57
go tool cover -html=coverage.out

0 commit comments

Comments
 (0)