godash/.gitlab/test.gitlab-ci.yml
2023-06-27 14:56:31 +02:00

15 lines
445 B
YAML

unit_tests:
rules: !reference [.rules:default, rules]
stage: test
image: golang:$GOLANG_VERSION-alpine
extends:
- .go-cache
script:
- go install gotest.tools/gotestsum@latest
- gotestsum --junitfile report.xml --format testname -- ./... -coverprofile=profile.cov
- go tool cover -func profile.cov
coverage: '/\(statements\)(?:\s+)?(\d+(?:\.\d+)?%)/'
artifacts:
when: always
reports:
junit: report.xml