forked from MilesCranmer/SymbolicRegression.jl
-
Notifications
You must be signed in to change notification settings - Fork 0
67 lines (64 loc) · 1.83 KB
/
CI.yml
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
name: CI
on:
push:
branches:
- '*'
paths:
- 'test/**'
- 'src/**'
- '.github/workflows/**'
- 'Project.toml'
pull_request:
branches:
- master
paths:
- 'test/**'
- 'src/**'
- '.github/workflows/**'
- 'Project.toml'
jobs:
test:
name: Julia ${{ matrix.julia-version }} - ${{ matrix.os }} - ${{ github.event_name }}
runs-on: ${{ matrix.os }}
timeout-minutes: 60
strategy:
fail-fast: false
matrix:
julia-version:
- '1.6.0'
- '1.7.1'
- '1.8.0'
os:
- ubuntu-latest
- windows-latest
- macOS-latest
steps:
- uses: actions/[email protected]
- name: "Set up Julia"
uses: julia-actions/[email protected]
with:
version: ${{ matrix.julia-version }}
- name: Cache dependencies
uses: actions/cache@v1 # Thanks FromFile.jl
env:
cache-name: cache-artifacts
with:
path: ~/.julia/artifacts
key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('**/Project.toml') }}
restore-keys: |
${{ runner.os }}-build-${{ env.cache-name }}-
${{ runner.os }}-build-
${{ runner.os }}-
- name: "Build package"
uses: julia-actions/julia-buildpkg@v1
- name: "Run tests"
run: |
julia --color=yes --project=. -e 'import Pkg; Pkg.add("Coverage")'
julia --color=yes --inline=yes --depwarn=yes --code-coverage=user --project=. -e 'import Pkg; Pkg.test(coverage=true)'
julia --color=yes --project=. coverage.jl
shell: bash
- name: Coveralls
uses: coverallsapp/github-action@master
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
path-to-lcov: coverage-lcov.info