Compare commits

..

4 Commits

Author SHA1 Message Date
John Donaldson 5ba58664b6 Merge branch 'add_coverage_report_html' into 'main'
Add more coverage artifacts

See merge request devs/moth!180
2022-10-25 21:27:42 +00:00
John Donaldson 190657f2fa Add more coverage artifacts 2022-10-25 13:48:58 -07:00
John Donaldson 73933447a9 Merge branch 'add_coverage_report_number' into 'main'
Add overall report coverage number

See merge request devs/moth!179
2022-10-25 20:37:56 +00:00
John Donaldson 3bd1cdcc56 Add overall report coverage number 2022-10-25 20:37:56 +00:00
1 changed files with 6 additions and 0 deletions

View File

@ -14,11 +14,17 @@ test:
- go test -coverprofile=coverage.txt -covermode=atomic -race ./... - go test -coverprofile=coverage.txt -covermode=atomic -race ./...
- go get github.com/boumenot/gocover-cobertura - go get github.com/boumenot/gocover-cobertura
- go run github.com/boumenot/gocover-cobertura < coverage.txt > coverage.xml - go run github.com/boumenot/gocover-cobertura < coverage.txt > coverage.xml
- go tool cover -html=coverage.txt -o coverage.html
- go tool cover -func coverage.txt
coverage: /\(statements\)(?:\s+)?(\d+(?:\.\d+)?%)/
artifacts: artifacts:
reports: reports:
coverage_report: coverage_report:
coverage_format: cobertura coverage_format: cobertura
path: coverage.xml path: coverage.xml
paths:
- coverage.html
- coverage.txt
push: push:
stage: push stage: push
rules: rules: