Need to iterate over the flattened array.

This commit is contained in:
Kale Kundert
2018-07-27 11:24:42 -07:00
parent d0ba242c46
commit bf127a63b2

View File

@@ -211,7 +211,7 @@ class ApproxScalar(ApproxBase):
the pre-specified tolerance.
"""
if _is_numpy_array(actual):
return all(a == self for a in actual)
return all(a == self for a in actual.flat)
# Short-circuit exact equality.
if actual == self.expected: