-
Notifications
You must be signed in to change notification settings - Fork 9
45 lines (36 loc) · 1.11 KB
/
push.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
name: Push
on: push
jobs:
build:
runs-on: ${{matrix.os}}
strategy:
matrix:
os: [ubuntu-latest]
python-version: ["3.7", "3.8", "3.9", "3.10", "3.11", "3.12"]
steps:
- uses: actions/checkout@v3
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Set up Cache
uses: actions/cache@v3
with:
path: ~/.cache/pip
key: |
${{ format('pip-{0}-{1}', matrix.python-version, hashFiles('setup.py')) }}
- name: Install Dependencies
run: |
pip install pip==23.*
pip install .[dev]
- name: Black
run: black src test --check --verbose
- name: Pytest
run: pytest --verbose --cov=./ --cov-report=xml
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v1.0.2
with:
token: ${{secrets.CODECOV_TOKEN}}
name: ${{matrix.python-version}}
file: ./coverage.xml
continue-on-error: true # I don't care THAT much about codecov