Skip to content

Commit

Permalink
Handle coverage only being on retried tests.
Browse files Browse the repository at this point in the history
gotestyourself/gotestsum#274

Updates gotestsum to v1.11.0
  • Loading branch information
Kyle Dixler committed Dec 6, 2023
1 parent 4af97b4 commit 15b022f
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 5 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/ci-run-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -235,7 +235,7 @@ jobs:
GITHUB_TOKEN: ${{ secrets.PULUMI_BOT_TOKEN }}
with:
repo: gotestyourself/gotestsum
tag: v1.8.1
tag: v1.11.0
cache: enable
- name: Install goteststats
uses: jaxxstorm/action-install-gh-release@v1.7.1
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -359,7 +359,7 @@ jobs:
find test-results -mindepth 1 -name '*.json' -mtime +7 -delete
test-collect-coverage:
needs: [unit-test, integration-test, acceptance-test]
if: ${{ inputs.enable-coverage }}
if: ${{ inputs.enable-coverage == true }}
runs-on: ubuntu-latest
steps:
- name: Retrieve code coverage statuses
Expand Down
3 changes: 1 addition & 2 deletions .github/workflows/on-pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -105,8 +105,7 @@ jobs:
&& 'macos-latest windows-latest'
|| ''
}}
# We'll only upload coverage artifacts with the periodic-coverage cron workflow.
enable-coverage: false
enable-coverage: true
secrets: inherit

prepare-release:
Expand Down
2 changes: 1 addition & 1 deletion scripts/go-test.py
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ def heartbeat():
os.mkdir(str(test_results_dir))

json_file = str(test_results_dir.joinpath(f'{test_run}.json'))
args = ['gotestsum', '--jsonfile', json_file, '--rerun-fails=1', '--packages', pkgs, '--'] + \
args = ['gotestsum', '--jsonfile', json_file, '--rerun-fails=1', '--rerun-fails-run-root-test', '--packages', pkgs, '--'] + \
opts
else:
args = ['go', 'test'] + args
Expand Down

0 comments on commit 15b022f

Please sign in to comment.