Skip to content

Commit b87c967

Browse files
committed
ci(matrix): prevent skipping the test job when test_matrix fails
1 parent b7ca0c1 commit b87c967

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

.github/workflows/test.yml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@ jobs:
3333
test:
3434
runs-on: ubuntu-latest
3535
needs: test_matrix
36+
if: always()
3637
steps:
3738
- uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3
3839
- uses: actions/setup-node@5e21ff4d9bc1a8cf6de233a3057d20ec6b3fb69d # v3
@@ -47,3 +48,9 @@ jobs:
4748
# https://github.com/lirantal/lockfile-lint#readme
4849
- name: Scan lockfile for security issues
4950
run: npx lockfile-lint --path package-lock.json
51+
- name: All matrix versions passed
52+
if: ${{ !(contains(needs.*.result, 'failure')) }}
53+
run: exit 0
54+
- name: Some matrix version failed
55+
if: ${{ contains(needs.*.result, 'failure') }}
56+
run: exit 1

0 commit comments

Comments
 (0)