Skip to content

Commit

Permalink
Update test fixture to avoid deprecation warning in pytest caching fo…
Browse files Browse the repository at this point in the history
…r numpy 1.24 arrays
  • Loading branch information
langmm committed Jul 30, 2024
1 parent b165408 commit af397be
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion run_script.sh
Original file line number Diff line number Diff line change
Expand Up @@ -31,5 +31,5 @@ if [ -n "$WITH_ASAN" ]; then
export DYLD_INSERT_LIBRARIES=$(clang -print-file-name=libclang_rt.asan_osx_dynamic.dylib)
fi

python -m pytest -svx tests/ --doctest-glob="docs/*.rst" --doctest-modules docs
python -m pytest -sv tests/ --doctest-glob="docs/*.rst" --doctest-modules docs
# make -C docs doctest -e PYTHON=$(python -c "import sys; import pathlib; print(pathlib.Path(sys.executable).resolve(strict=True))") -e DYLD_INSERT_LIBRARIES=$(clang -print-file-name=libclang_rt.asan_osx_dynamic.dylib)
4 changes: 2 additions & 2 deletions tests/test_units.py
Original file line number Diff line number Diff line change
Expand Up @@ -394,8 +394,8 @@ def cls(self):
'g'),
'units_equiv': 'kilogram',
'units_incompat': '°F'}),
({'args': (np.arange(4, dtype=np.int8), 'g'),
'args_compat': (0.001 * np.arange(4, dtype=np.int8), 'kg'),
({'args': (np.arange(3, dtype=np.int8), 'g'),
'args_compat': (0.001 * np.arange(3, dtype=np.int8), 'kg'),
'units_equiv': 'grams',
'units_incompat': 'seconds'}),
({'args': (np.int32(3), 'degC'),
Expand Down

0 comments on commit af397be

Please sign in to comment.