Skip to content

Commit 86b5481

Browse files
authored
Fix mock __array__ interface (#3821)
Addresses a backwards compatibility bug introduced in #3803
1 parent eb0b5cc commit 86b5481

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

tests/test_matrix.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -61,8 +61,8 @@ class ArrayLike:
6161
def __init__(self, data):
6262
self.data = data
6363

64-
def __array__(self, dtype=None, copy=None):
65-
return np.asarray(self.data, dtype=dtype, copy=copy)
64+
def __array__(self, **kwargs):
65+
return np.asarray(self.data, **kwargs)
6666

6767
p = mat._HeatMapper(ArrayLike(self.x_norm), **self.default_kws)
6868
npt.assert_array_equal(p.plot_data, self.x_norm)

0 commit comments

Comments
 (0)