summaryrefslogtreecommitdiff
path: root/numpy/testing/_private/utils.py
diff options
context:
space:
mode:
authorMark Harfouche <mark.harfouche@gmail.com>2019-05-12 13:03:22 -0400
committerMark Harfouche <mark.harfouche@gmail.com>2019-05-12 13:03:22 -0400
commit366f9b8fc3dbc92baf7c5ba82a44b3fdb72e863d (patch)
tree82238205b0b90b9af518ec0751cdb9be593db2ae /numpy/testing/_private/utils.py
parent8c3411a334d8a46b46d3148b96ecb4dfcd4e3c7b (diff)
downloadnumpy-366f9b8fc3dbc92baf7c5ba82a44b3fdb72e863d.tar.gz
Ensure that reduced is a 1D array
Diffstat (limited to 'numpy/testing/_private/utils.py')
-rw-r--r--numpy/testing/_private/utils.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/numpy/testing/_private/utils.py b/numpy/testing/_private/utils.py
index 75685f7fd..0e739ae00 100644
--- a/numpy/testing/_private/utils.py
+++ b/numpy/testing/_private/utils.py
@@ -784,7 +784,7 @@ def assert_array_compare(comparison, x, y, err_msg='', verbose=True,
if isinstance(val, bool):
cond = val
- reduced = array(val)
+ reduced = array([val])
else:
reduced = val.ravel()
cond = reduced.all()