Skip to content

Commit b70b74b

Browse files
committed
[gh actions] Split Linux build matrix
The default Linux Ubuntu 22+ does not support Python < 3.8. To keep testing Python 3.6 and 3.7 use an Ubuntu 20.04 build matrix.
1 parent 969680a commit b70b74b

File tree

1 file changed

+23
-1
lines changed

1 file changed

+23
-1
lines changed

.github/workflows/run-tests.yml

Lines changed: 23 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,29 @@ jobs:
1313
strategy:
1414
matrix:
1515
os: [ubuntu-latest]
16-
python-version: ["3.6", "3.7", "3.8", "3.9", "3.10"]
16+
python-version: ["3.8", "3.9", "3.10"]
17+
steps:
18+
- uses: actions/checkout@v2
19+
- name: Setup Python ${{ matrix.python-version }}
20+
uses: actions/setup-python@v2
21+
with:
22+
python-version: ${{ matrix.python-version }}
23+
- name: Display Python version
24+
run: python -c "import sys; print(sys.version)"
25+
- name: Install dependencies
26+
run: |
27+
python setup.py install
28+
pip install -r requirements-test.txt
29+
- name: Run tests
30+
run: pytest
31+
# The default Linux Ubuntu 22+ does not support Python < 3.8 any longer
32+
# To keep testing Python < 3.8, use Ubuntu 20
33+
linux_legacy_tests:
34+
runs-on: ${{ matrix.os }}
35+
strategy:
36+
matrix:
37+
os: [ubuntu-20.04]
38+
python-version: ["3.6", "3.7"]
1739
steps:
1840
- uses: actions/checkout@v2
1941
- name: Setup Python ${{ matrix.python-version }}

0 commit comments

Comments
 (0)