Skip to content

Commit 71d2347

Browse files
committed
some new tests fails
1 parent bd30df3 commit 71d2347

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

pandas/tests/indexes/test_numpy_compat.py

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -155,12 +155,10 @@ def test_numpy_ufuncs_reductions(index, func, request):
155155
# TODO: overlap with tests.series.test_ufunc.test_reductions
156156
if len(index) == 0:
157157
pytest.skip("Test doesn't make sense for empty index.")
158-
has_str = any(isinstance(x, str) for x in index)
159-
has_int = any(isinstance(x, int) for x in index)
160-
if has_str and has_int:
158+
if getattr(index, "inferred_type", None) in ["mixed", "mixed-integer"]:
161159
request.applymarker(
162160
pytest.mark.xfail(
163-
reason="Cannot compare mixed types (int and str) in ufunc reductions"
161+
reason="Cannot compare mixed types in ufunc reductions"
164162
)
165163
)
166164

0 commit comments

Comments
 (0)