-
Notifications
You must be signed in to change notification settings - Fork 4
50 lines (43 loc) · 1.4 KB
/
test_oonidata.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
name: test oonidata
on: push
jobs:
run_tests:
name: ${{ matrix.os }} / ${{ matrix.python-version }}
runs-on: ${{ matrix.os }}-latest
strategy:
matrix:
os: [Ubuntu]
python-version: ["3.8", "3.9", "3.10", "3.11", "3.12"]
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Install hatch
run: pip install hatch
- name: Set up datadir cache
uses: actions/cache@v3
with:
path: oonidata/tests/data/datadir/
key: oonidata-tests-data-datadir
- name: Set up measurements cache
uses: actions/cache@v3
with:
path: oonidata/tests/data/measurements/
key: oonidata-tests-data-measurements
- name: Set up raw_measurements cache
uses: actions/cache@v3
with:
path: oonidata/tests/data/raw_measurements/
key: oonidata-tests-data-raw_measurements-${{ hashFiles('tests/conftest.py') }}
- name: Run all tests
run: hatch run cov
working-directory: ./oonidata/
- name: Upload coverage to codecov
uses: codecov/codecov-action@v3
with:
flags: oonidata
working-directory: ./oonidata/
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}