diff --git a/.github/workflows/unitcoverage.yaml b/.github/workflows/unitcoverage.yaml index 659e1bdd0a..06fc6acc34 100644 --- a/.github/workflows/unitcoverage.yaml +++ b/.github/workflows/unitcoverage.yaml @@ -19,7 +19,7 @@ jobs: fetch-depth: 1 - name: Run Unit Tests run: | - go test ./pkg/... -coverprofile coverage.out + go test -coverpkg=./... -covermode=atomic -coverprofile=coverage.out ./pkg/... go tool cover -func coverage.out - name: On Failure, Launch Debug Session if: ${{ failure() }} diff --git a/scripts/test-unit b/scripts/test-unit index 730885c227..4569553384 100755 --- a/scripts/test-unit +++ b/scripts/test-unit @@ -1,2 +1,2 @@ #!/bin/bash -go test -cover -v ./pkg/... +go test -cover -coverpkg=./... -covermode=atomic -v ./pkg/...