From 357638ad65ca2c1b10b4b70743c50b745f55bfa0 Mon Sep 17 00:00:00 2001 From: Dongdong Tian Date: Tue, 16 Jan 2024 11:19:06 +0800 Subject: [PATCH] Set rtol to 1e-4 to avoid system-dependent floating-point differences --- pygmt/tests/test_x2sys_cross.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pygmt/tests/test_x2sys_cross.py b/pygmt/tests/test_x2sys_cross.py index 17638d83c45..7aa2e4653c0 100644 --- a/pygmt/tests/test_x2sys_cross.py +++ b/pygmt/tests/test_x2sys_cross.py @@ -233,5 +233,5 @@ def test_x2sys_cross_trackvalues(): assert isinstance(output, pd.DataFrame) assert output.shape == (14338, 12) # Check mean of track 1 values (z_1) and track 2 values (z_2) - npt.assert_allclose(output.z_1.mean(), -2422.418556) - npt.assert_allclose(output.z_2.mean(), -2402.268364) + npt.assert_allclose(output.z_1.mean(), -2422.418556, rtol=1e-4) + npt.assert_allclose(output.z_2.mean(), -2402.268364, rtol=1e-4)