summaryrefslogtreecommitdiff
path: root/numpy/linalg
diff options
context:
space:
mode:
authorJulian Taylor <jtaylor.debian@googlemail.com>2016-08-05 00:38:56 +0200
committerJulian Taylor <jtaylor.debian@googlemail.com>2016-08-05 00:55:45 +0200
commit07800e53ea335bc64514e9b4b0a5e5711fd39684 (patch)
treee0fd8a0f751d605547eaaf008f6acb1578a983f9 /numpy/linalg
parent4c415d2dbacb9117e295ad634bbe1d88de5b3ed6 (diff)
downloadnumpy-07800e53ea335bc64514e9b4b0a5e5711fd39684.tar.gz
BUG: fix float16 type not being called due to wrong ordering
closes gh-7897
Diffstat (limited to 'numpy/linalg')
-rw-r--r--numpy/linalg/tests/test_linalg.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/numpy/linalg/tests/test_linalg.py b/numpy/linalg/tests/test_linalg.py
index 60486d4ce..a89378acd 100644
--- a/numpy/linalg/tests/test_linalg.py
+++ b/numpy/linalg/tests/test_linalg.py
@@ -877,11 +877,11 @@ class _TestNorm(object):
an = norm(at, 2)
assert_(issubclass(an.dtype.type, np.floating))
- assert_almost_equal(an, 2.0**(1.0/2.0))
+ assert_almost_equal(an, an.dtype.type(2.0)**an.dtype.type(1.0/2.0))
an = norm(at, 4)
assert_(issubclass(an.dtype.type, np.floating))
- assert_almost_equal(an, 2.0**(1.0/4.0))
+ assert_almost_equal(an, an.dtype.type(2.0)**an.dtype.type(1.0/4.0))
an = norm(at, np.inf)
assert_(issubclass(an.dtype.type, np.floating))