mirror of https://github.com/k3s-io/k3s
Fix coverage reporting to include all packages, not just those with tests
Signed-off-by: Brad Davidson <brad.davidson@rancher.com>pull/3564/head
parent
c833183517
commit
6b3285b7e3
|
@ -19,7 +19,7 @@ jobs:
|
||||||
fetch-depth: 1
|
fetch-depth: 1
|
||||||
- name: Run Unit Tests
|
- name: Run Unit Tests
|
||||||
run: |
|
run: |
|
||||||
go test ./pkg/... -coverprofile coverage.out
|
go test -coverpkg=./... -covermode=atomic -coverprofile=coverage.out ./pkg/...
|
||||||
go tool cover -func coverage.out
|
go tool cover -func coverage.out
|
||||||
- name: On Failure, Launch Debug Session
|
- name: On Failure, Launch Debug Session
|
||||||
if: ${{ failure() }}
|
if: ${{ failure() }}
|
||||||
|
|
|
@ -1,2 +1,2 @@
|
||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
go test -cover -v ./pkg/...
|
go test -cover -coverpkg=./... -covermode=atomic -v ./pkg/...
|
||||||
|
|
Loading…
Reference in New Issue