From a1bf3c82f8be72e2c6514b470130fc55b43be936 Mon Sep 17 00:00:00 2001 From: Andrea Zonca Date: Mon, 16 Oct 2017 04:19:30 -0700 Subject: [PATCH 1/2] Fix missing parentheses --- python/libsharp/tests/test_legendre_table.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/python/libsharp/tests/test_legendre_table.py b/python/libsharp/tests/test_legendre_table.py index 1d42af5..a7eb0bb 100644 --- a/python/libsharp/tests/test_legendre_table.py +++ b/python/libsharp/tests/test_legendre_table.py @@ -12,8 +12,8 @@ def test_compare_legendre_table_with_scipy(): Plm_p = sph_harm(m, np.arange(m, lmax + 1), 0, theta)[None, :] if not np.allclose(Plm_p, Plm): - print Plm_p - print Plm + print(Plm_p) + print(Plm) return ok_, np.allclose(Plm_p, Plm) yield test(np.pi/2, 0, 10) From 0c95cfe9d98f036923888dac57f5aee0215892e5 Mon Sep 17 00:00:00 2001 From: Andrea Zonca Date: Mon, 16 Oct 2017 04:20:28 -0700 Subject: [PATCH 2/2] backward compatibility for Python 2.7 --- python/libsharp/tests/test_legendre_table.py | 1 + 1 file changed, 1 insertion(+) diff --git a/python/libsharp/tests/test_legendre_table.py b/python/libsharp/tests/test_legendre_table.py index a7eb0bb..eb02df2 100644 --- a/python/libsharp/tests/test_legendre_table.py +++ b/python/libsharp/tests/test_legendre_table.py @@ -1,3 +1,4 @@ +from __future__ import print_function import numpy as np from numpy.testing import assert_almost_equal