Skip to content

Commit b0177e1

Browse files
authored
[MNT] testing with no extras
This PR adds a "no extras" set of CI tests, ensuring that the package also runs with minimal dependencies installed. Also changes the `all_extras` dependency set to not install test or build dependencies - this is meant to be user facing.
2 parents 50b5ad9 + 647392e commit b0177e1

3 files changed

Lines changed: 44 additions & 4 deletions

File tree

.github/workflows/test.yml

Lines changed: 38 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,8 @@ concurrency:
1515
cancel-in-progress: true
1616

1717
jobs:
18-
build:
18+
test-no-extras:
19+
name: test-no-extras
1920
strategy:
2021
matrix:
2122
python-version: ["3.9", "3.10", "3.11", "3.12", "3.13"]
@@ -39,7 +40,42 @@ jobs:
3940
python -m pip install --upgrade pip
4041
python -m pip install build
4142
42-
make install-all-extras
43+
make install-no-extras-for-test
44+
45+
- name: Test with pytest
46+
run: |
47+
python -m pytest tests -p no:warnings
48+
49+
- name: Test with pytest
50+
run: |
51+
python -m pytest src/hyperactive -p no:warnings
52+
53+
test-all-extras:
54+
name: test-all-extras
55+
strategy:
56+
matrix:
57+
python-version: ["3.9", "3.10", "3.11", "3.12", "3.13"]
58+
os: ["macos-latest", "windows-latest", "ubuntu-latest"]
59+
60+
fail-fast: false
61+
62+
runs-on: ${{ matrix.os }}
63+
timeout-minutes: 30
64+
65+
steps:
66+
- uses: actions/checkout@v4
67+
68+
- name: Set up Python ${{ matrix.python-version }}
69+
uses: actions/setup-python@v5
70+
with:
71+
python-version: ${{ matrix.python-version }}
72+
73+
- name: Install dependencies
74+
run: |
75+
python -m pip install --upgrade pip
76+
python -m pip install build
77+
78+
make install-all-extras-for-test
4379
4480
- name: Test with pytest
4581
run: |

Makefile

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -83,6 +83,12 @@ install-build-requirements:
8383
install-all-extras:
8484
python -m pip install .[all_extras]
8585

86+
install-no-extras-for-test:
87+
python -m pip install .[test]
88+
89+
install-all-extras-for-test:
90+
python -m pip install .[all_extras,test]
91+
8692
install-editable:
8793
pip install -e .
8894

pyproject.toml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -61,8 +61,6 @@ test = [
6161
"pathos",
6262
]
6363
all_extras = [
64-
"hyperactive[build]",
65-
"hyperactive[test]",
6664
"hyperactive[integrations]",
6765
]
6866

0 commit comments

Comments
 (0)