diff --git a/simsz/__init__.py b/simsz/__init__.py index 5252bd1..001afbf 100644 --- a/simsz/__init__.py +++ b/simsz/__init__.py @@ -3,5 +3,6 @@ try: from simsz.filters import get_tSZ_signal_aperture_photometry + from simsz.utils import Mpc_to_arcmin except ModuleNotFoundError: pass \ No newline at end of file diff --git a/tests/test_simtools.py b/tests/test_simtools.py index d4fd353..edfd160 100644 --- a/tests/test_simtools.py +++ b/tests/test_simtools.py @@ -25,5 +25,4 @@ def test_f_sz(self): T_CMB = cosmo.Tcmb0 fsz = simtools.f_sz(freq,T_CMB) fsz_expected = 12.509 - assert u.isclose(fsz,fsz_expected), - f"Expected {fsz_expected}, but got {fsz}" \ No newline at end of file + assert u.isclose(fsz,fsz_expected),f"Expected {fsz_expected}, but got {fsz}" \ No newline at end of file diff --git a/tests/test_szcluster.py b/tests/test_szcluster.py index 5796cc4..3f99931 100644 --- a/tests/test_szcluster.py +++ b/tests/test_szcluster.py @@ -89,7 +89,7 @@ def test_Pth_Battaglia2012(self): x = radii/R200 #As defined in Battaglia 2012 Pth_expected = P0 * (x/xc)**(-0.3) * (1 + (x/xc))**(-beta) result = Pth_Battaglia2012(radii,R200,-0.3,1.0,beta,xc,P0) - assert np.allclose(result, Pth_expected), f"Expected {Pth_expected}, but got {result}" + assert np.allclose(result, Pth_expected),f"Expected {Pth_expected}, but got {result}" def test_epp_to_y(self): ''' diff --git a/tests/test_utils.py b/tests/test_utils.py index 0eaed31..bb76c79 100644 --- a/tests/test_utils.py +++ b/tests/test_utils.py @@ -22,7 +22,7 @@ def test_arcmin_to_Mpc(self): (cosmo,sigma8,ns) = get_mock_cosmology() value_expected = 0.559219683539306 value_calculated = arcmin_to_Mpc(r, z, cosmo) - assert u.isclose(value_calculated, value_expected), f"Expected {value_expected}, but got {value_calculated}" + assert u.isclose(value_calculated, value_expected),f"Expected {value_expected}, but got {value_calculated}" def test_Mpc_to_arcmin(self): r = 1 @@ -30,4 +30,4 @@ def test_Mpc_to_arcmin(self): (cosmo,sigma8,ns) = get_mock_cosmology() value_expected = 1.7882060117608733 value_calculated = Mpc_to_arcmin(r, z, cosmo) - assert u.isclose(value_calculated, value_expected), f"Expected {value_expected}, but got {value_calculated}" \ No newline at end of file + assert u.isclose(value_calculated, value_expected),f"Expected {value_expected}, but got {value_calculated}" \ No newline at end of file