Skip to content

Commit a6f464a

Browse files
cleanup usage get_unit_from_pa_dtype
1 parent f16bf76 commit a6f464a

File tree

1 file changed

+2
-6
lines changed

1 file changed

+2
-6
lines changed

pandas/tests/extension/test_arrow.py

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -67,10 +67,7 @@
6767

6868
pa = pytest.importorskip("pyarrow")
6969

70-
from pandas.core.arrays.arrow.array import (
71-
ArrowExtensionArray,
72-
get_unit_from_pa_dtype,
73-
)
70+
from pandas.core.arrays.arrow.array import ArrowExtensionArray
7471
from pandas.core.arrays.arrow.extension_types import ArrowPeriodType
7572

7673

@@ -539,8 +536,7 @@ def _get_expected_reduction_dtype(self, arr, op_name: str, skipna: bool):
539536
elif pa.types.is_date(pa_type):
540537
cmp_dtype = ArrowDtype(pa.duration("s"))
541538
elif pa.types.is_time(pa_type):
542-
unit = get_unit_from_pa_dtype(pa_type)
543-
cmp_dtype = ArrowDtype(pa.duration(unit))
539+
cmp_dtype = ArrowDtype(pa.duration(pa_type.unit))
544540
else:
545541
cmp_dtype = ArrowDtype(pa.duration(pa_type.unit))
546542
else:

0 commit comments

Comments
 (0)