-
Notifications
You must be signed in to change notification settings - Fork 61
92 lines (83 loc) · 2.06 KB
/
ubuntu.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
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
name: Ubuntu
on:
push:
branches:
- master
paths-ignore:
- "conda_env/**"
- "devtools/**"
- "docs/**"
- "samples/**"
- "licenses/**"
- "hooks/**"
- ".**"
- "!.github/**"
- "**.md"
- "**.yml"
- "**.txt"
- "**.in"
- "**.cfg"
pull_request:
branches:
- master
paths-ignore:
- "conda_env/**"
- "devtools/**"
- "docs/**"
- "samples/**"
- "licenses/**"
- "hooks/**"
- ".**"
- "!.github/**"
- "**.md"
- "**.yml"
- "**.txt"
- "**.in"
- "**.cfg"
env:
MPLBACKEN: "Agg"
jobs:
test_ubuntu:
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
max-parallel: 6
matrix:
python-version: [3.7, 3.8, 3.9]
os: ["ubuntu-18.04", "ubuntu-latest"]
steps:
- uses: actions/checkout@v2
with:
ref: ${{github.event.pull_request.head.ref}}
repository: ${{github.event.pull_request.head.repo.full_name}}
- name: Install Python ${{ matrix.python-version }} on ${{ matrix.os }}
uses: conda-incubator/setup-miniconda@v2
with:
auto-update-conda: true
auto-activate-base: false
activate-environment: test
mamba-version: "*"
channels: pytorch,conda-forge,defaults
environment-file: .github/config/linux_win_env.yml
python-version: ${{ matrix.python-version }}
- name: Check conda env
shell: bash -l {0}
run: .github/config/check_env.sh
- name: Install XenonPy
shell: bash -l {0}
run: |
pip install .
- name: Test XenonPy
shell: bash -l {0}
env:
api_key: ${{ secrets.api_key }}
run: |
pytest --cov=./ --cov-report=xml tests
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v1
env:
OS: ${{ matrix.os }}
PYTHON: ${{ matrix.python-version }}
with:
env_vars: OS,PYTHON
fail_ci_if_error: false