Test Python + NumPy in CI#405
Conversation
564a865 to
39c39a6
Compare
| on: [push, pull_request] | ||
|
|
||
| jobs: | ||
| check_format: |
There was a problem hiding this comment.
The format job wasn't working correctly anymore – the default Python version in Azure Pipelines no longer works with our version of black – so it needed maintenance. I moved it to GitHub Actions so all the Python CI would be in one place.
If you'd like to remove Azure Pipelines entirely, I could move the one remaining job to GitHub Actions in a follow-on PR.
| working-directory: python/tests | ||
| run: uv run --project . black --check .. | ||
|
|
||
| build_wheels_quick: |
There was a problem hiding this comment.
Since the Python tests depend on cibuildwheel, I broke out a separate build task with just the wheels needed for testing, so that the Python tests don't take quite so long to start. (As is, the builds we need for testing take 2 minutes, which makes for slow iteration times.)
| name: cibw-wheels-quick | ||
| path: ./wheelhouse/*.whl | ||
|
|
||
| test_wheels: |
There was a problem hiding this comment.
This is the new test task
| except: | ||
| __version__ = "2.0.0rc10" | ||
|
|
||
| with open("README.md", "r", encoding="utf8") as fh: |
There was a problem hiding this comment.
This was causing a warning or an error in build, since it conflicts with the readme directive in pyproject.toml.
| make && ./tester | ||
| displayName: Run unit tests | ||
|
|
||
| - job: python_format |
There was a problem hiding this comment.
This is the job I moved to GitHub Actions and fixed.
Add test tasks to GitHub Actions which test the generated wheels using different Python and NumPy versions. It seems to be working well at this point. I've added four tests for issues #400 and they are all failing in the way I expect – surfacing disparities between
num_face_verticesandnumpy_num_face_vertices().I've also added tests for issue #401 which is passing, and #402 is also covered in the #400 tests so those will need further investigation at a later time.
Closes #403