Skip to content

Commit 94eece0

Browse files
committed
fix: install package via pip in CI
1 parent 8f5807d commit 94eece0

2 files changed

Lines changed: 14 additions & 3 deletions

File tree

.github/workflows/ci.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -43,10 +43,10 @@ jobs:
4343
- name: Install test dependencies
4444
run: |
4545
python -m pip install --upgrade pip
46-
python -m pip install maturin pytest scipy
46+
python -m pip install pytest scipy
4747
48-
- name: Build extension in editable mode
49-
run: maturin develop
48+
- name: Install package
49+
run: python -m pip install .
5050

5151
- name: Run test suite
5252
run: pytest -x -v

tests/test_project_metadata.py

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,8 +23,19 @@ def workflow_python_versions() -> list[str]:
2323
return sorted(set(re.findall(r'- "(3\.\d+)"', workflow)))
2424

2525

26+
def workflow_contents() -> str:
27+
return (ROOT / ".github/workflows/ci.yml").read_text()
28+
29+
2630
def test_python_version_support_matches_current_bindings() -> None:
2731
expected = ["3.10", "3.11", "3.12", "3.13"]
2832

2933
assert pyproject_python_versions() == expected
3034
assert workflow_python_versions() == expected
35+
36+
37+
def test_ci_avoids_maturin_develop_without_virtualenv() -> None:
38+
workflow = workflow_contents()
39+
40+
assert "maturin develop" not in workflow
41+
assert "python -m pip install ." in workflow

0 commit comments

Comments
 (0)