From f8fc8d2cc3944ccd4615e93f61ca4c689eb5c844 Mon Sep 17 00:00:00 2001 From: Sebastian Berg Date: Sat, 28 May 2022 12:19:59 -0700 Subject: TST: Ignore promotion warning in linalg test calculating atol --- numpy/linalg/tests/test_linalg.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'numpy') diff --git a/numpy/linalg/tests/test_linalg.py b/numpy/linalg/tests/test_linalg.py index ebbd92539..39eb10b92 100644 --- a/numpy/linalg/tests/test_linalg.py +++ b/numpy/linalg/tests/test_linalg.py @@ -1803,9 +1803,9 @@ class TestCholesky: c = np.linalg.cholesky(a) b = np.matmul(c, c.transpose(t).conj()) - assert_allclose(b, a, - err_msg=f'{shape} {dtype}\n{a}\n{c}', - atol=500 * a.shape[0] * np.finfo(dtype).eps) + with np.no_nep50_warning(): + atol = 500 * a.shape[0] * np.finfo(dtype).eps + assert_allclose(b, a, atol=atol, err_msg=f'{shape} {dtype}\n{a}\n{c}') def test_0_size(self): class ArraySubclass(np.ndarray): -- cgit v1.2.1