summaryrefslogtreecommitdiff
path: root/numpy/core/tests
diff options
context:
space:
mode:
authorAllan Haldane <allan.haldane@gmail.com>2017-09-14 12:00:36 -0400
committerAllan Haldane <allan.haldane@gmail.com>2017-09-25 21:22:13 -0400
commit6bfef271d8df4c5aa4af9075defd672b11f1cbc0 (patch)
treef0a9bf48dfb4647f692e3d1db50377bd762b12ff /numpy/core/tests
parent95e9bfaba04064530899b8ba78cddec2ff505b4c (diff)
downloadnumpy-6bfef271d8df4c5aa4af9075defd672b11f1cbc0.tar.gz
MAINT: arrayprint.py formatters no longer require ravel'd data
Diffstat (limited to 'numpy/core/tests')
-rw-r--r--numpy/core/tests/test_arrayprint.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/numpy/core/tests/test_arrayprint.py b/numpy/core/tests/test_arrayprint.py
index 90ba79f30..90e82ed74 100644
--- a/numpy/core/tests/test_arrayprint.py
+++ b/numpy/core/tests/test_arrayprint.py
@@ -297,6 +297,12 @@ class TestPrintOptions(object):
assert_equal(repr(a), 'array([ 0., 1., 2., 3.])')
assert_equal(repr(np.array(1.)), 'array(1.)')
+ def test_sign_spacing_structured(self):
+ a = np.ones(2, dtype='f,f')
+ assert_equal(repr(a), "array([(1., 1.), (1., 1.)],\n"
+ " dtype=[('f0', '<f4'), ('f1', '<f4')])")
+ assert_equal(repr(a[0]), "(1., 1.)")
+
def test_unicode_object_array():
import sys