Skip to content

Commit

Permalink
ensure extension modules are present in built wheel (#256)
Browse files Browse the repository at this point in the history
* add test command to import c extension modules

* add comment about test_command in cibuildwheel

* fix import syntax
  • Loading branch information
zacharyburnett committed May 17, 2024
1 parent fa14c81 commit a99a933
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
1 change: 1 addition & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,5 +23,6 @@ jobs:
# Until we have arm64 runners, we can't automatically test arm64 wheels
- cp3*-macosx_arm64
sdist: true
test_command: python -c "from stcal.ramp_fitting.ols_cas22 import _ramp, _jump, _fit"
secrets:
pypi_token: ${{ secrets.PYPI_PASSWORD_STSCI_MAINTAINER }}
2 changes: 2 additions & 0 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@
Options.docstrings = True
Options.annotate = False

# importing these extension modules is tested in `.github/workflows/build.yml`;
# when adding new modules here, make sure to add them to the `test_command` entry there
extensions = [
Extension(
"stcal.ramp_fitting.ols_cas22._ramp",
Expand Down

0 comments on commit a99a933

Please sign in to comment.