@@ -243,6 +243,27 @@ def test_get_reverse_indexer(self):
243
243
expected = np .array ([4 , 2 , 3 , 6 , 7 ], dtype = np .intp )
244
244
tm .assert_numpy_array_equal (result , expected )
245
245
246
+ @pytest .mark .parametrize ("dtype" , ["int64" , "int32" ])
247
+ def test_array_equal_fast (self , dtype ):
248
+ # GH#50592
249
+ left = np .arange (1 , 100 , dtype = dtype )
250
+ right = np .arange (1 , 100 , dtype = dtype )
251
+ assert lib .array_equal_fast (left , right )
252
+
253
+ @pytest .mark .parametrize ("dtype" , ["int64" , "int32" ])
254
+ def test_array_equal_fast_not_equal (self , dtype ):
255
+ # GH#50592
256
+ left = np .array ([1 , 2 ], dtype = dtype )
257
+ right = np .array ([2 , 2 ], dtype = dtype )
258
+ assert not lib .array_equal_fast (left , right )
259
+
260
+ @pytest .mark .parametrize ("dtype" , ["int64" , "int32" ])
261
+ def test_array_equal_fast_not_equal_shape (self , dtype ):
262
+ # GH#50592
263
+ left = np .array ([1 , 2 , 3 ], dtype = dtype )
264
+ right = np .array ([2 , 2 ], dtype = dtype )
265
+ assert not lib .array_equal_fast (left , right )
266
+
246
267
247
268
def test_cache_readonly_preserve_docstrings ():
248
269
# GH18197
0 commit comments