diff options
Diffstat (limited to 'numpy/core')
-rw-r--r-- | numpy/core/tests/test_umath.py | 17 |
1 files changed, 5 insertions, 12 deletions
diff --git a/numpy/core/tests/test_umath.py b/numpy/core/tests/test_umath.py index 2f7322412..ffe653d18 100644 --- a/numpy/core/tests/test_umath.py +++ b/numpy/core/tests/test_umath.py @@ -48,14 +48,6 @@ def bad_arcsinh(): # The eps for float128 is 1-e33, so this is way bigger return abs((v1 / v2) - 1.0) > 1e-23 -if platform.machine() == 'aarch64' and bad_arcsinh(): - skip_longcomplex_msg = ('Trig functions of np.longcomplex values known to be ' - 'inaccurate on aarch64 for some compilation ' - 'configurations, should be fixed by building on a ' - 'platform using glibc>2.17') -else: - skip_longcomplex_msg = '' - class _FilterInvalids: def setup(self): @@ -3440,13 +3432,14 @@ class TestComplexFunctions: x_series = np.logspace(-20, -3.001, 200) x_basic = np.logspace(-2.999, 0, 10, endpoint=False) - if dtype is np.longcomplex: + if glibc_older_than_2_17 and dtype is np.longcomplex: + if (platform.machine() == 'aarch64' and bad_arcsinh()): + pytest.skip("Trig functions of np.longcomplex values known " + "to be inaccurate on aarch64 for some compilation " + "configurations.") # It's not guaranteed that the system-provided arc functions # are accurate down to a few epsilons. (Eg. on Linux 64-bit) # So, give more leeway for long complex tests here: - # Can use 2.1 for > Ubuntu LTS Trusty (2014), glibc = 2.19. - if skip_longcomplex_msg: - pytest.skip(skip_longcomplex_msg) check(x_series, 50.0*eps) else: check(x_series, 2.1*eps) |