-
Notifications
You must be signed in to change notification settings - Fork 0
59 lines (55 loc) · 1.63 KB
/
bench.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
name: benchmarks
on: push
jobs:
bench:
name: Benchmarks
runs-on: ubuntu-latest
container:
image: ghcr.io/nnpdf/lhapdf:v2
credentials:
username: ${{ github.repository_owner }}
password: ${{ github.token }}
steps:
- uses: actions/checkout@v2
with:
# tags needed for dynamic versioning
fetch-depth: 0
- name: Install and configure Poetry
uses: snok/install-poetry@v1
with:
virtualenvs-create: false
installer-parallel: true
- name: Install dependencies
run: poetry install --no-interaction --no-root --with test
- name: Install project
# it is required to repeat extras, otherwise they will be removed from
# the environment
run: poetry install --no-interaction
- name: Install task runner
run: pip install poethepoet
- name: Lint with pylint
run: |
# Search for actual errors
poe lint
# For warnings instead return always zero
poe lint-warnings
- name: Get data files
id: cache-data-files
uses: actions/cache@v3
with:
path: data_files
key: data_files-v2
- name: Download data files
if: steps.cache-data_files.outputs.cache-hit != 'true'
run: |
sh download_test_data.sh
- name: Test with pytest
run: |
poe bench
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v2
with:
files: ./coverage.xml
flags: bench
name: codecov-umbrella
fail_ci_if_error: false