Skip to content

Commit 34dcbfc

Browse files
committed
workflows/tests.yml: skip coverage upload when brew tests is skipped
Signed-off-by: Patrick Linnane <patrick@linnane.io>
1 parent b5c24d7 commit 34dcbfc

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

.github/workflows/tests.yml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -304,6 +304,7 @@ jobs:
304304
echo "filenames=${filenames%,}" >> "$GITHUB_OUTPUT"
305305
306306
- uses: codecov/codecov-action@e79a6962e0d4c0c17b229090214935d2e33f8354 # v6.0.1
307+
if: github.event_name == 'pull_request' || matrix.name != 'tests (online)'
307308
with:
308309
working-directory: ${{ steps.set-up-homebrew.outputs.repository-path }}
309310
files: ${{ steps.junit_xml.outputs.filenames }}
@@ -312,13 +313,15 @@ jobs:
312313
report_type: test_results
313314

314315
- uses: codecov/codecov-action@e79a6962e0d4c0c17b229090214935d2e33f8354 # v6.0.1
316+
if: github.event_name == 'pull_request' || matrix.name != 'tests (online)'
315317
with:
316318
working-directory: ${{ steps.set-up-homebrew.outputs.repository-path }}
317319
files: Library/Homebrew/test/coverage/coverage.xml
318320
disable_search: true
319321
token: ${{ secrets.CODECOV_TOKEN }}
320322

321-
- uses: actions/upload-code-coverage@abb5995db9e0199b0e2bb9dbd136fce4cb1ec4d3 # v1
323+
- uses: actions/upload-code-coverage@abb5995db9e0199b0e2bb9dbd136fce4cb1ec4d3 # v1.3.0
324+
if: github.event_name == 'pull_request' || matrix.name != 'tests (online)'
322325
with:
323326
file: ${{ steps.set-up-homebrew.outputs.repository-path }}/Library/Homebrew/test/coverage/coverage.xml
324327
language: Ruby

0 commit comments

Comments
 (0)