-
Notifications
You must be signed in to change notification settings - Fork 59
69 lines (62 loc) · 2 KB
/
CompatCheck.yml
File metadata and controls
69 lines (62 loc) · 2 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
name: CompatCheck
on:
push:
branches:
- 'main'
- 'release-'
tags: '*'
paths:
- 'Project.toml'
- 'test/Project.toml'
pull_request:
types: [opened, synchronize, reopened, ready_for_review, converted_to_draft]
workflow_dispatch:
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
# Cancel intermediate builds: only if it is a pull request build.
cancel-in-progress: ${{ startsWith(github.ref, 'refs/pull/') }}
jobs:
setup-matrix:
runs-on: ubuntu-latest
outputs:
groups: ${{ steps.mk.outputs.groups }}
version: ${{ steps.mk.outputs.version }}
os: ${{ steps.mk.outputs.os }}
steps:
- uses: actions/checkout@v6
- id: mk
shell: bash
run: |
# Auto-discover test groups from all subdirectory names.
groups=$(find test -mindepth 1 -maxdepth 1 -type d \
| xargs -I{} basename {} | sort \
| jq -R -s -c '[split("\n")[] | select(length > 0)]')
echo "groups=${groups}" >> "$GITHUB_OUTPUT"
compatcheck:
name: "Compat (${{ matrix.group }}, Julia ${{ matrix.julia-version }})"
needs: setup-matrix
if: github.event.pull_request.draft != true
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
downgrade_mode: ['deps']
group: ${{ fromJSON(needs.setup-matrix.outputs.groups) }}
julia-version: ['1', '1.10']
steps:
- uses: actions/checkout@v6
- uses: julia-actions/setup-julia@v2
with:
version: ${{ matrix.julia-version }}
- uses: julia-actions/cache@v3
- uses: julia-actions/julia-downgrade-compat@v2
with:
mode: ${{ matrix.downgrade_mode }}
skip: Random, LinearAlgebra, Test, Combinatorics
julia_version: ${{ matrix.julia-version }}
- uses: julia-actions/julia-buildpkg@v1
- uses: julia-actions/julia-runtest@v1
with:
test_args: '${{ matrix.group }} --fast'
env:
JULIA_NUM_THREADS: "4"