Skip to content

Commit 2c365ac

Browse files
committed
Install all test dependencies in GH action
1 parent ae89258 commit 2c365ac

File tree

1 file changed

+16
-17
lines changed

1 file changed

+16
-17
lines changed

.github/workflows/python-package.yml

Lines changed: 16 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -5,31 +5,30 @@ name: Python package
55

66
on:
77
push:
8-
branches: [ "main" ]
8+
branches: ["main"]
99
pull_request:
10-
branches: [ "main" ]
10+
branches: ["main"]
1111

1212
jobs:
1313
build:
14-
1514
runs-on: ubuntu-latest
1615
strategy:
1716
fail-fast: false
1817
matrix:
1918
python-version: ["3.9", "3.10", "3.11"]
2019

2120
steps:
22-
- uses: actions/checkout@v4
23-
- name: Set up Python ${{ matrix.python-version }}
24-
uses: actions/setup-python@v3
25-
with:
26-
python-version: ${{ matrix.python-version }}
27-
- name: Install dependencies
28-
run: |
29-
python -m pip install --upgrade pip
30-
python -m pip install pytest
31-
if [ -f requirements.txt ]; then pip install -r requirements.txt; fi
32-
- uses: pre-commit/[email protected]
33-
- name: Test with pytest
34-
run: |
35-
pytest
21+
- uses: actions/checkout@v4
22+
- name: Set up Python ${{ matrix.python-version }}
23+
uses: actions/setup-python@v3
24+
with:
25+
python-version: ${{ matrix.python-version }}
26+
- name: Install dependencies
27+
run: |
28+
python -m pip install --upgrade pip
29+
python -m pip install ".[test]"
30+
if [ -f requirements.txt ]; then pip install -r requirements.txt; fi
31+
- uses: pre-commit/[email protected]
32+
- name: Test with pytest
33+
run: |
34+
pytest

0 commit comments

Comments
 (0)