File tree Expand file tree Collapse file tree 3 files changed +28
-26
lines changed
Expand file tree Collapse file tree 3 files changed +28
-26
lines changed Original file line number Diff line number Diff line change 77jobs :
88 test :
99 runs-on : ubuntu-latest
10+ strategy :
11+ matrix :
12+ python : [3.6, 3.7, 3.8]
1013
1114 steps :
1215 - uses : actions/checkout@v1
1316
14- - name : Set up Python 3.7
17+ - name : Set up Python
1518 uses : actions/setup-python@v1
1619 with :
17- python-version : 3.7
20+ python-version : ${{ matrix.python }}
1821
1922 - name : Install Poetry
2023 uses : dschep/install-poetry-action@v1.3
@@ -24,12 +27,11 @@ jobs:
2427 poetry config virtualenvs.in-project false
2528 poetry config virtualenvs.path ~/.virtualenvs
2629
27- - name : Install Dependencies
28- run : poetry install
29- if : steps.cache.outputs.cache-hit != 'true'
30+ - name : Install Tox
31+ run : pip install tox
3032
31- - name : Test with pytest
32- run : poetry run pytest --cov-report term-missing --cov-report=xml --cov=labthings ./tests
33+ - name : Run Tox
34+ run : tox -e py # Run tox using the version of Python in `PATH`
3335
3436 publish :
3537 runs-on : ubuntu-latest
Original file line number Diff line number Diff line change 99jobs :
1010 test :
1111 runs-on : ubuntu-latest
12+ strategy :
13+ matrix :
14+ python : [3.6, 3.7, 3.8]
1215
1316 steps :
1417 - uses : actions/checkout@v1
1518
16- - name : Set up Python 3.7
19+ - name : Set up Python
1720 uses : actions/setup-python@v1
1821 with :
19- python-version : 3.7
22+ python-version : ${{ matrix.python }}
2023
2124 - name : Install Poetry
2225 uses : dschep/install-poetry-action@v1.3
2326
24- - name : Cache Poetry virtualenv
25- uses : actions/cache@v1
26- id : cache
27- with :
28- path : ~/.virtualenvs
29- key : poetry-${{ hashFiles('**/poetry.lock') }}
30- restore-keys : |
31- poetry-${{ hashFiles('**/poetry.lock') }}
32-
3327 - name : Set Poetry config
3428 run : |
3529 poetry config virtualenvs.in-project false
3630 poetry config virtualenvs.path ~/.virtualenvs
3731
38- - name : Install Dependencies
39- run : poetry install
40- if : steps.cache.outputs.cache-hit != 'true'
41-
42- - name : Code Quality
43- run : poetry run black . --check
32+ - name : Install Tox
33+ run : pip install tox
4434
45- - name : Test with pytest
46- run : poetry run pytest --cov-report term-missing --cov-report=xml --cov=labthings ./tests
35+ - name : Run Tox
36+ run : tox -e py # Run tox using the version of Python in `PATH`
4737
4838 - name : Upload coverage to Codecov
4939 uses : codecov/codecov-action@v1
Original file line number Diff line number Diff line change 1+ [tox]
2+ isolated_build = true
3+ envlist = py36, py37, py38
4+
5+ [testenv]
6+ whitelist_externals = poetry
7+ commands =
8+ poetry install -v
9+ poetry run black . --check
10+ poetry run pytest tests/
You can’t perform that action at this time.
0 commit comments