Skip to content

Commit e278bc2

Browse files
committed
CI: Optimize tests in ci.yml
Avoid unnecessary checks for certain jobs.
1 parent 6304fc2 commit e278bc2

File tree

1 file changed

+16
-1
lines changed

1 file changed

+16
-1
lines changed

.github/workflows/ci.yml

Lines changed: 16 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,8 @@ on:
2222
pull_request:
2323
paths: *paths-filter
2424

25+
workflow_dispatch:
26+
2527
env:
2628
ELIXIR_ASSERT_TIMEOUT: 2000
2729
ELIXIRC_OPTS: "--warnings-as-errors"
@@ -37,25 +39,35 @@ jobs:
3739

3840
strategy:
3941
fail-fast: false
42+
4043
matrix:
4144
include:
4245
# NOTE: When updating latest Erlang/OTP version, also update it in
4346
# .github/workflows/documentation.yml
4447
- otp_version: "28.1"
48+
erlc_opts: "warnings_as_errors"
4549
deterministic: true
50+
skip_tests: true
51+
4652
- otp_version: "28.1"
4753
erlc_opts: "warnings_as_errors"
4854
coverage: true
55+
skip_tests: true
56+
4957
- otp_version: "28.1"
50-
otp_latest: true
5158
erlc_opts: "warnings_as_errors"
59+
5260
- otp_version: "27.3"
5361
erlc_opts: "warnings_as_errors"
62+
5463
- otp_version: "27.0"
5564
erlc_opts: "warnings_as_errors"
65+
5666
- otp_version: "26.0"
67+
5768
- otp_version: master
5869
development: true
70+
5971
- otp_version: maint
6072
development: true
6173

@@ -83,15 +95,18 @@ jobs:
8395
run: bin/elixir --version
8496

8597
- name: Check format
98+
if: ${{ !matrix.skip_tests }}
8699
run: |
87100
make test_formatted && \
88101
echo "All Elixir source code files are properly formatted."
89102
90103
- name: Erlang test suite
104+
if: ${{ !matrix.skip_tests }}
91105
run: make test_erlang
92106
continue-on-error: ${{ matrix.development }}
93107

94108
- name: Elixir test suite
109+
if: ${{ matrix.coverage || !matrix.skip_tests }}
95110
run: make test_elixir
96111
continue-on-error: ${{ matrix.development }}
97112
env:

0 commit comments

Comments
 (0)