From fadfb451509ee567f691059b50503d3c225a9e83 Mon Sep 17 00:00:00 2001 From: "Christopher J. Markiewicz" Date: Tue, 7 Jan 2020 11:17:52 -0500 Subject: [PATCH] TEST: Numpy changed longdouble str representations in 1.18 --- nibabel/tests/test_h5py_compat.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/nibabel/tests/test_h5py_compat.py b/nibabel/tests/test_h5py_compat.py index 26d70b6e55..af5c50989c 100644 --- a/nibabel/tests/test_h5py_compat.py +++ b/nibabel/tests/test_h5py_compat.py @@ -40,5 +40,8 @@ def test_disabled_h5py_cases(): # Verify that the root cause is present # If any tests fail, they will likely be these, so they may be # ill-advised... - assert_equal(str(np.longdouble), str(np.float64)) + if LooseVersion(np.__version__) < '1.18': + assert_equal(str(np.longdouble), str(np.float64)) + else: + assert_not_equal(str(np.longdouble), str(np.float64)) assert_not_equal(np.longdouble, np.float64)