diff options
author | Mike Taves <mwtoews@gmail.com> | 2022-10-27 06:02:37 +1300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-10-26 10:02:37 -0700 |
commit | 13d55a3c2f016a58a6e9d6b8086f338e07c7478f (patch) | |
tree | a792928b2b4f959bdd685fba9dcf6ef7d049f145 /numpy/ma/tests | |
parent | 12c2b7dd62fc0c14b81c8892ed5f4f59cc94d09c (diff) | |
download | numpy-13d55a3c2f016a58a6e9d6b8086f338e07c7478f.tar.gz |
MAINT: remove u-prefix for former Unicode strings (#22479)
Diffstat (limited to 'numpy/ma/tests')
-rw-r--r-- | numpy/ma/tests/test_core.py | 6 | ||||
-rw-r--r-- | numpy/ma/tests/test_regression.py | 2 |
2 files changed, 4 insertions, 4 deletions
diff --git a/numpy/ma/tests/test_core.py b/numpy/ma/tests/test_core.py index b1c080a56..385e85e5b 100644 --- a/numpy/ma/tests/test_core.py +++ b/numpy/ma/tests/test_core.py @@ -589,14 +589,14 @@ class TestMaskedArray: np.set_printoptions(**oldopts) def test_0d_unicode(self): - u = u'caf\xe9' + u = 'caf\xe9' utype = type(u) arr_nomask = np.ma.array(u) arr_masked = np.ma.array(u, mask=True) assert_equal(utype(arr_nomask), u) - assert_equal(utype(arr_masked), u'--') + assert_equal(utype(arr_masked), '--') def test_pickling(self): # Tests pickling @@ -5261,7 +5261,7 @@ class TestMaskedConstant: def test_coercion_unicode(self): a_u = np.zeros((), 'U10') a_u[()] = np.ma.masked - assert_equal(a_u[()], u'--') + assert_equal(a_u[()], '--') @pytest.mark.xfail(reason="See gh-9750") def test_coercion_bytes(self): diff --git a/numpy/ma/tests/test_regression.py b/numpy/ma/tests/test_regression.py index 7e76eb054..cb3d0349f 100644 --- a/numpy/ma/tests/test_regression.py +++ b/numpy/ma/tests/test_regression.py @@ -37,7 +37,7 @@ class TestRegression: def test_masked_array_repr_unicode(self): # Ticket #1256 - repr(np.ma.array(u"Unicode")) + repr(np.ma.array("Unicode")) def test_atleast_2d(self): # Ticket #1559 |