Skip to content

Commit e6ccea7

Browse files
committed
Duplicate Python environment list from tox in GitHub Actions matrix strategy
1 parent 86f80bc commit e6ccea7

File tree

1 file changed

+4
-19
lines changed

1 file changed

+4
-19
lines changed

.github/workflows/python-tox.yml

Lines changed: 4 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -5,31 +5,16 @@ jobs:
55
# Credit: https://github.community/t/duplicate-checks-on-push-and-pull-request-simultaneous-event/18012
66
if: github.event.push || github.event.pull_request.head.repo.full_name != github.repository
77
runs-on: ubuntu-latest
8+
strategy:
9+
matrix:
10+
python: [2.7, 3.5, 3.6, 3.7, 3.8, pypy-2.7, pypy3
811
steps:
912
- uses: actions/checkout@v2
1013
with:
1114
submodules: true
1215
- uses: actions/setup-python@v2
1316
with:
14-
python-version: 2.7
15-
- uses: actions/setup-python@v2
16-
with:
17-
python-version: 3.5
18-
- uses: actions/setup-python@v2
19-
with:
20-
python-version: 3.6
21-
- uses: actions/setup-python@v2
22-
with:
23-
python-version: 3.7
24-
- uses: actions/setup-python@v2
25-
with:
26-
python-version: 3.8
27-
- uses: actions/setup-python@v2
28-
with:
29-
python-version: pypy-2.7
30-
- uses: actions/setup-python@v2
31-
with:
32-
python-version: pypy3
17+
python-version: ${{ matrix.python }}
3318
- run: pip install tox
3419
- run: tox --parallel
3520
env:

0 commit comments

Comments
 (0)