-
Notifications
You must be signed in to change notification settings - Fork 5
42 lines (36 loc) · 1.22 KB
/
build.yaml
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
name: Tests
on:
push:
branches:
- main
jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
matrix:
python-version: [3.6.8, 3.7, 3.8, 3.9]
os: [macos-latest, ubuntu-20.04]
steps:
- uses: actions/checkout@v2
- name: Build using Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- name: pip install dependencies [pip]
if: ${{ matrix.python-version >= 3.7 }}
run: |
python -m pip install pip --upgrade pip
pip install pytest
if [ -f requirements.txt ]; then pip install -r requirements.txt; fi
pip install -e .
- name: pip install dependencies 36 [pip]
if: ${{ matrix.python-version < 3.7 }}
run: |
python -m pip install pip --upgrade pip
pip install pytest
if [ -f requirements.txt ]; then pip install -r requirements.txt; fi
if [ ${{ matrix.python-version }} == 3.6 ]; then pip install dataclasses>=0.7; fi
pip install -e .
- name: unit tests [pytest]
run: |
pytest --show-capture=no -v --disable-warnings --junitxml=pytest.xml