@@ -12,36 +12,29 @@ def test_tuple_setitem_with_datetime_tz(self):
1212 # 16889
1313 # support setitem with datetimeindex with tz
1414 mask = np .array ([True , False , True , False ])
15+
1516 idx = pd .date_range ('20010101' , periods = 4 , tz = 'UTC' )
1617 df = pd .DataFrame ({'a' : np .arange (4 )}, index = idx ).astype ('float64' )
18+
1719 result = df .copy ()
1820 result .loc [mask , :] = df .loc [mask , :]
1921 tm .assert_frame_equal (result , df )
2022
21- def test_setitem_with_datetime_tz (self ):
22- mask = np .array ([True , False , True , False ])
23- idx = pd .date_range ('20010101' , periods = 4 , tz = 'UTC' )
24- df = pd .DataFrame ({'a' : np .arange (4 )}, index = idx ).astype ('float64' )
2523 result = df .copy ()
2624 result .loc [mask ] = df .loc [mask ]
2725 tm .assert_frame_equal (result , df )
2826
29- def test_tuple_setitem_with_datetime (self ):
30- mask = np .array ([True , False , True , False ])
3127 idx = pd .date_range ('20010101' , periods = 4 )
3228 df = pd .DataFrame ({'a' : np .arange (4 )}, index = idx ).astype ('float64' )
29+
3330 result = df .copy ()
34- result .loc [mask ] = df .loc [mask ]
31+ result .loc [mask , : ] = df .loc [mask , : ]
3532 tm .assert_frame_equal (result , df )
36-
37- def test_setitem_datetime (self ):
38- mask = np .array ([True , False , True , False ])
39- idx = pd .date_range ('20010101' , periods = 4 )
40- df = pd .DataFrame ({'a' : np .arange (4 )}, index = idx ).astype ('float64' )
33+
4134 result = df .copy ()
4235 result .loc [mask ] = df .loc [mask ]
4336 tm .assert_frame_equal (result , df )
44-
37+
4538 def test_indexing_with_datetime_tz (self ):
4639
4740 # 8260
0 commit comments