diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2021-07-26 21:09:51 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2021-07-26 21:09:51 +0300 |
commit | f57f1c6cd8a89454bb8a4a1b965738dcc8007d5d (patch) | |
tree | adaa136d2f5423dc75fef3e31e2cdb635734628f /doc/ci/unit_test_reports.md | |
parent | 81f9ca3c644d6e14de09b61202b67dbb6e321fe7 (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'doc/ci/unit_test_reports.md')
-rw-r--r-- | doc/ci/unit_test_reports.md | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/doc/ci/unit_test_reports.md b/doc/ci/unit_test_reports.md index f845c79ef45..7677908e93a 100644 --- a/doc/ci/unit_test_reports.md +++ b/doc/ci/unit_test_reports.md @@ -114,16 +114,15 @@ ruby: ### Go example -Use the following job in `.gitlab-ci.yml`, and ensure you use `-set-exit-code`, -otherwise the pipeline is marked successful, even if the tests fail: +Use the following job in `.gitlab-ci.yml`: ```yaml -## Use https://github.com/jstemmer/go-junit-report to generate a JUnit report format XML file with go +## Use https://github.com/gotestyourself/gotestsum to generate a JUnit report format XML file with go golang: stage: test script: - - go get -u github.com/jstemmer/go-junit-report - - go test -v 2>&1 | go-junit-report -set-exit-code > report.xml + - go get gotest.tools/gotestsum + - gotestsum --junitfile report.xml --format testname artifacts: when: always reports: |