Skip to content

Commit

Permalink
Test wheels with both latest and oldest NumPy
Browse files Browse the repository at this point in the history
  • Loading branch information
kbvw committed Aug 23, 2024
1 parent 7b9e1be commit b624267
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 10 deletions.
5 changes: 5 additions & 0 deletions packaging/python/oldest_numpy_requirements.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
numpy==1.20.3;python_version=='3.9' and platform_machine!='arm64'
numpy==1.21.6;python_version=='3.9' and platform_machine=='arm64'
numpy==1.21.6;python_version=='3.10'
numpy==1.23.5;python_version=='3.11'
numpy==1.26.4;python_version=='3.12'
9 changes: 1 addition & 8 deletions packaging/python/test_requirements.txt
Original file line number Diff line number Diff line change
@@ -1,10 +1,3 @@
# General test requirements
pytest
setuptools;python_version>='3.12' # From 3.12, no longer installed by default

# Oldest supported numpy versions
numpy==1.20.3;python_version=='3.9' and platform_machine!='arm64'
numpy==1.21.6;python_version=='3.9' and platform_machine=='arm64'
numpy==1.21.6;python_version=='3.10'
numpy==1.23.5;python_version=='3.11'
numpy==1.26.4;python_version=='3.12'
numpy
10 changes: 8 additions & 2 deletions packaging/python/test_wheels.sh
Original file line number Diff line number Diff line change
Expand Up @@ -269,8 +269,14 @@ if echo $compile_options | grep "NRN_ENABLE_CORENEURON=ON" > /dev/null ; then
has_coreneuron=true
fi

# run tests
test_wheel "${python_exe}"
# run tests with latest NumPy
echo " == Running tests with latest NumPy == "
time test_wheel "${python_exe}"

# run tests with oldest supported NumPy
echo " == Running tests with oldest supported NumPy == "
$python_exe -m pip install -r packaging/python/oldest_numpy_requirements.txt
time test_wheel "${python_exe}"

# cleanup
if [[ "$use_venv" != "false" ]]; then
Expand Down

0 comments on commit b624267

Please sign in to comment.