1818from  pandas .errors  import  PerformanceWarning , UnsortedIndexError 
1919from  pandas .core .dtypes .dtypes  import  CategoricalDtype 
2020from  pandas .core .indexes .base  import  InvalidIndexError 
21- from  pandas .core .dtypes .cast  import  construct_1d_array_from_listlike 
21+ from  pandas .core .dtypes .cast  import  construct_1d_object_array_from_listlike 
2222from  pandas ._libs .lib  import  Timestamp 
2323
2424import  pandas .util .testing  as  tm 
@@ -913,7 +913,7 @@ def test_from_product_invalid_input(self):
913913    def  test_from_product_datetimeindex (self ):
914914        dt_index  =  date_range ('2000-01-01' , periods = 2 )
915915        mi  =  pd .MultiIndex .from_product ([[1 , 2 ], dt_index ])
916-         etalon  =  construct_1d_array_from_listlike ([(1 , pd .Timestamp (
916+         etalon  =  construct_1d_object_array_from_listlike ([(1 , pd .Timestamp (
917917            '2000-01-01' )), (1 , pd .Timestamp ('2000-01-02' )), (2 , pd .Timestamp (
918918                '2000-01-01' )), (2 , pd .Timestamp ('2000-01-02' ))])
919919        tm .assert_numpy_array_equal (mi .values , etalon )
@@ -938,11 +938,11 @@ def test_values_boxed(self):
938938                  (1 , pd .Timestamp ('2000-01-04' )),
939939                  (2 , pd .Timestamp ('2000-01-02' )),
940940                  (3 , pd .Timestamp ('2000-01-03' ))]
941-         mi  =  pd .MultiIndex .from_tuples (tuples )
942-         tm . assert_numpy_array_equal ( mi . values , 
943-                                      construct_1d_array_from_listlike ( tuples ) )
941+         result  =  pd .MultiIndex .from_tuples (tuples )
942+         expected   =   construct_1d_object_array_from_listlike ( tuples ) 
943+         tm . assert_numpy_array_equal ( result . values ,  expected )
944944        # Check that code branches for boxed values produce identical results 
945-         tm .assert_numpy_array_equal (mi .values [:4 ], mi [:4 ].values )
945+         tm .assert_numpy_array_equal (result .values [:4 ], result [:4 ].values )
946946
947947    def  test_append (self ):
948948        result  =  self .index [:3 ].append (self .index [3 :])
0 commit comments