11name : CI
2+
23on :
34 push :
45 branches :
56 - main
67 tags : ['*']
78 pull_request :
9+
810concurrency :
911 # Skip intermediate builds: always.
1012 # Cancel intermediate builds: only if it is a pull request build.
1113 group : ${{ github.workflow }}-${{ github.ref }}
1214 cancel-in-progress : ${{ startsWith(github.ref, 'refs/pull/') }}
15+
1316jobs :
1417 test :
1518 name : Julia ${{ matrix.version }} - ${{ matrix.os }} - ${{ matrix.arch }} - ${{ github.event_name }}
@@ -25,16 +28,52 @@ jobs:
2528 - ubuntu-latest
2629 arch :
2730 - x64
31+
2832 steps :
2933 - uses : actions/checkout@v4
30- - uses : julia-actions/setup-julia@v1
34+
35+ - name : Set up Julia
36+ uses : julia-actions/setup-julia@v1
3137 with :
3238 version : ${{ matrix.version }}
3339 arch : ${{ matrix.arch }}
34- - uses : julia-actions/cache@v1
35- - uses : julia-actions/julia-buildpkg@v1
36- - uses : julia-actions/julia-runtest@v1
37- - uses : julia-actions/julia-processcoverage@v1
38- - uses : codecov/codecov-action@v3
40+
41+ - name : Cache Julia dependencies
42+ uses : julia-actions/cache@v1
43+ with :
44+ path : ~/.julia
45+ key : julia-deps-${{ hashFiles('**/*.toml') }}
46+
47+ - name : Install Julia dependencies
48+ run : julia -e 'import Pkg; Pkg.instantiate()'
49+
50+ - name : Build Julia package
51+ uses : julia-actions/julia-buildpkg@v1
52+
53+ - name : Install PyCall dependencies
54+ run : julia -e 'import Pkg; Pkg.add("PyCall"); Pkg.build("PyCall")'
55+
56+ - name : Run Julia tests
57+ uses : julia-actions/julia-runtest@v1
58+ with :
59+ project : .
60+
61+ - name : Set up Python
62+ uses : actions/setup-python@v2
63+ with :
64+ python-version : 3.12
65+
66+ - name : Install Python dependencies
67+ run : |
68+ python -m pip install -r requirements/pycall.txt
69+
70+ # - name: Run Python tests
71+ # run: python test/test.py
72+
73+ - name : Generate and upload code coverage
74+ uses : julia-actions/julia-processcoverage@v1
75+
76+ - name : Upload to Codecov
77+ uses : codecov/codecov-action@v3
3978 with :
4079 files : lcov.info
0 commit comments