@@ -60,19 +60,20 @@ def test_eq_mismatched_type(self, other):
60
60
expected = pd .array ([True , True ])
61
61
tm .assert_extension_array_equal (result , expected )
62
62
63
- def test_logical_length_mismatch_raises (self , all_logical_operators ):
63
+ @pytest .mark .parametrize ("other" , [[True , False ], [True , False , True , False ]])
64
+ def test_logical_length_mismatch_raises (self , other , all_logical_operators ):
64
65
op_name = all_logical_operators
65
66
a = pd .array ([True , False , None ], dtype = "boolean" )
66
67
msg = "Lengths must match"
67
68
68
69
with pytest .raises (ValueError , match = msg ):
69
- getattr (a , op_name )([ True , False ] )
70
+ getattr (a , op_name )(other )
70
71
71
72
with pytest .raises (ValueError , match = msg ):
72
- getattr (a , op_name )(np .array ([ True , False ] ))
73
+ getattr (a , op_name )(np .array (other ))
73
74
74
75
with pytest .raises (ValueError , match = msg ):
75
- getattr (a , op_name )(pd .array ([ True , False ] , dtype = "boolean" ))
76
+ getattr (a , op_name )(pd .array (other , dtype = "boolean" ))
76
77
77
78
def test_logical_nan_raises (self , all_logical_operators ):
78
79
op_name = all_logical_operators
0 commit comments