Skip to content

Commit 88fe157

Browse files
committed
Adress review comments
1 parent 22a6bff commit 88fe157

File tree

1 file changed

+6
-5
lines changed

1 file changed

+6
-5
lines changed

pandas/tests/series/indexing/test_setitem.py

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
NaT,
1010
Series,
1111
Timestamp,
12-
array,
12+
array as pd_array,
1313
date_range,
1414
period_range,
1515
)
@@ -127,12 +127,13 @@ def test_setitem_boolean_different_order(self, string_series):
127127

128128
tm.assert_series_equal(copy, expected)
129129

130-
def test_setitem_boolean_ea_type(self):
130+
def test_setitem_boolean_nullable_int_types(self, any_nullable_int_dtype):
131131
# GH: 26468
132-
s = Series(array([5, 6, 7, 8], dtype="Int64"))
133-
s[s > 6] = Series(range(4), dtype="Int64")
132+
ser = Series(pd_array([5, 6, 7, 8], dtype="Int64"))
133+
loc_ser = Series(range(4), dtype="Int64")
134+
ser[ser > 6] = loc_ser.loc[loc_ser > 1]
134135
expected = Series([5, 6, 2, 3], dtype="Int64")
135-
tm.assert_series_equal(s, expected)
136+
tm.assert_series_equal(ser, expected)
136137

137138

138139
class TestSetitemViewCopySemantics:

0 commit comments

Comments
 (0)