|
1 | | -# This is a basic workflow to help you get started with Actions |
2 | | - |
3 | 1 | name: runtests |
4 | 2 |
|
5 | | -# Controls when the action will run. |
6 | 3 | on: |
7 | | - # Triggers the workflow on push or pull request events but only for the main branch |
8 | 4 | push: |
9 | 5 | branches: [ main ] |
10 | 6 | pull_request: |
11 | 7 | branches: [ main ] |
12 | | - |
13 | | - # Allows you to run this workflow manually from the Actions tab |
14 | 8 | workflow_dispatch: |
15 | 9 |
|
16 | | -# A workflow run is made up of one or more jobs that can run sequentially or in parallel |
17 | 10 | jobs: |
18 | | - # This workflow contains a single job called "build" |
19 | 11 | test: |
20 | | - # The type of runner that the job will run on |
21 | 12 | runs-on: ${{ matrix.os }} |
22 | 13 | strategy: |
| 14 | + fail-fast: false |
23 | 15 | matrix: |
24 | | - julia-version: ['~1.6', '~1.7'] |
| 16 | + julia-version: [lts, "1", pre] |
25 | 17 | os: [ubuntu-latest] |
| 18 | + timeout-minutes: 60 |
| 19 | + permissions: # needed to allow julia-actions/cache to proactively delete old caches that it has created |
| 20 | + actions: write |
| 21 | + contents: read |
26 | 22 |
|
27 | | - # Steps represent a sequence of tasks that will be executed as part of the job |
28 | 23 | steps: |
29 | | - # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it |
30 | | - - uses: actions/checkout@v2 |
| 24 | + - uses: actions/checkout@v4 |
31 | 25 |
|
32 | | - # Setup Julia environment |
33 | 26 | - name: "Setup Julia" |
34 | | - uses: julia-actions/setup-julia@v1 |
| 27 | + uses: julia-actions/setup-julia@v2 |
35 | 28 | with: |
36 | 29 | version: ${{ matrix.julia-version }} |
| 30 | + - uses: julia-actions/cache@v2 |
| 31 | + - uses: julia-actions/julia-buildpkg@v1 |
37 | 32 |
|
38 | | - # Cache binary artifacts |
39 | | - - uses: actions/cache@v4 |
40 | | - env: |
41 | | - cache-name: cache-artifacts |
42 | | - with: |
43 | | - path: | |
44 | | - ~/.julia/artifacts |
45 | | - ~/.julia/packages |
46 | | - ~/.julia/registries |
47 | | - key: ${{ runner.os }}-test-${{ env.cache-name }}-${{ hashFiles('**/Project.toml') }} |
48 | | - restore-keys: | |
49 | | - ${{ runner.os }}-test-${{ env.cache-name }}- |
50 | | - ${{ runner.os }}-test- |
51 | | - ${{ runner.os }}- |
52 | | -
|
53 | | - # run unit tests |
54 | | - - name: "run unit tests" |
| 33 | + - name: "run tests" |
55 | 34 | uses: julia-actions/julia-runtest@v1 |
56 | 35 | with: |
57 | 36 | coverage: false |
0 commit comments