Skip to content

Commit 654b406

Browse files
committed
test skipping 32-bit matrix configuration
1 parent 407e95b commit 654b406

File tree

1 file changed

+43
-0
lines changed

1 file changed

+43
-0
lines changed

.github/workflows/matrix.yml

Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
name: Test filtering Matrix jobs
2+
3+
on:
4+
merge_group:
5+
pull_request:
6+
workflow_dispatch:
7+
8+
concurrency:
9+
group: ${{ github.workflow }}-${{ github.ref }}
10+
cancel-in-progress: true
11+
12+
jobs:
13+
build:
14+
strategy:
15+
fail-fast: false
16+
matrix:
17+
bits: [32, 64]
18+
os:
19+
- macos-latest
20+
- ubuntu-latest
21+
- windows-latest
22+
runs-on: ${{ matrix.os }}
23+
defaults:
24+
run:
25+
shell: bash
26+
steps:
27+
- name: Filter
28+
if: ${{ matrix.bits == 32 && github.event_name != 'merge_group' }}
29+
run: exit 0
30+
- name: Task
31+
run: echo "Task not filtered out"
32+
33+
matrix-status:
34+
if: ${{ always() }}
35+
needs: [build]
36+
runs-on: ubuntu-latest
37+
steps:
38+
- name: Successful
39+
if: ${{ !(contains(needs.*.result, 'failure')) }}
40+
run: exit 0
41+
- name: Failing
42+
if: ${{ (contains(needs.*.result, 'failure')) }}
43+
run: exit 1

0 commit comments

Comments
 (0)