Skip to content

Commit 4e6cca2

Browse files
maxrjonesjhamman
andauthored
Specify hatch envs using GitHub actions matrix for v3 tests (zarr-developers#1728)
* Specify v3 hatch envs using GitHub actions matrix * Update .github/workflows/test-v3.yml Co-authored-by: Joe Hamman <[email protected]> * Update .github/workflows/test-v3.yml Co-authored-by: Joe Hamman <[email protected]> * test on 3.12 too * no 3.12 --------- Co-authored-by: Joe Hamman <[email protected]> Co-authored-by: Joe Hamman <[email protected]>
1 parent 15a9747 commit 4e6cca2

File tree

1 file changed

+11
-4
lines changed

1 file changed

+11
-4
lines changed

.github/workflows/test-v3.yml

Lines changed: 11 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -10,15 +10,22 @@ on:
1010
branches: [ v3 ]
1111

1212
jobs:
13-
run-tests:
13+
test:
14+
name: py=${{ matrix.python-version }}, np=${{ matrix.numpy-version }}, deps=${{ matrix.dependency-set }}
1415

1516
runs-on: ubuntu-latest
17+
strategy:
18+
matrix:
19+
python-version: ['3.10', '3.11']
20+
numpy-version: ['1.24', '1.26']
21+
dependency-set: ["minimal", "optional"]
22+
1623
steps:
1724
- uses: actions/checkout@v3
1825
- name: Set up Python
1926
uses: actions/setup-python@v4
2027
with:
21-
python-version: '3.11'
28+
python-version: ${{ matrix.python-version }}
2229
cache: 'pip'
2330
- name: Install Hatch
2431
run: |
@@ -29,8 +36,8 @@ jobs:
2936
hatch env create
3037
- name: Run Tests
3138
run: |
32-
hatch run test:run
39+
hatch env run --env test.py${{ matrix.python-version }}-${{ matrix.numpy-version }}-${{ matrix.dependency-set }} run
3340
- name: Run mypy
3441
continue-on-error: true
3542
run: |
36-
hatch run test:run-mypy
43+
hatch run test:run-mypy

0 commit comments

Comments
 (0)