-
Notifications
You must be signed in to change notification settings - Fork 2
44 lines (38 loc) · 979 Bytes
/
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
name: Run Tests
on:
pull_request:
branches: [ main ]
push:
branches: [ main ]
jobs:
tests:
name: Tests
env:
ENV_NAME: hera_qm_tests
PYTHON: ${{ matrix.python-version }}
OS: ${{ matrix.os }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, macos-latest]
python-version: [3.9, '3.10', "3.11", "3.12"]
fail-fast: false
steps:
- uses: actions/checkout@main
with:
fetch-depth: 1
- name: Setup Python
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Install
run: |
pip install --upgrade pip
pip install .[tests]
- name: Run Tests
run: |
pytest --cov-report xml:./coverage.xml
- name: Upload Coverage (Ubuntu)
if: matrix.os == 'ubuntu-latest' && success()
run: |
bash <(curl -s https://codecov.io/bash) -t ${{ secrets.CODECOV_TOKEN }}