Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 8 additions & 3 deletions .github/workflows/build-wheels.yml
Original file line number Diff line number Diff line change
Expand Up @@ -310,12 +310,11 @@ jobs:
name: sdist
path: dist

# Test the wheels (only on tags before publishing)
# Test the built wheels by installing and importing from site-packages
test-wheels:
name: Test wheels on ${{ matrix.os }} - Python ${{ matrix.python-version }}
needs: [build-wheels]
runs-on: ${{ matrix.os }}
if: startsWith(github.ref, 'refs/tags/')
strategy:
fail-fast: false
matrix:
Expand Down Expand Up @@ -350,8 +349,14 @@ jobs:
pip install pytest pytest-cov

- name: Run tests
shell: bash
run: |
pytest -v mortie/tests/test_tools.py mortie/tests/test_polygon_regression.py
# Run from a temp directory so Python imports the installed wheel,
# not the local source tree
cp -r mortie/tests /tmp/mortie_tests
cp pyproject.toml /tmp/
cd /tmp
pytest -v mortie_tests/test_tools.py mortie_tests/test_polygon_regression.py

# Publish to TestPyPI on tag (before production publish)
publish-testpypi:
Expand Down