Skip and document failure of test_equal_zero_nan_NP on recent numpy

This commit is contained in:
Benjamin A. Beasley
2023-10-30 07:43:17 -04:00
parent 08d98bcdf8
commit 34be7893c4
+9 -1
View File
@@ -75,7 +75,15 @@ find pint -type f -exec \
%pyproject_save_files pint
%check
%pytest
%global numpy_version %(\
%{python3} -c 'import numpy; print(numpy.__version__)' || echo 0)
# test_equal_zero_nan_NP fails with numpy 1.25.1
# https://github.com/hgrecco/pint/issues/1825
%if v"%{numpy_version}" >= v"1.25.1"
k="${k-}${k+ and }not (TestCompareNeutral and test_equal_zero_nan_NP)"
%endif
%pytest -k "${k-}"
%files -n python3-pint -f %{pyproject_files}
%{_bindir}/pint-convert