Skip to content

Commit ea92c45

Browse files
CI: xfail numpy-dev (#35502)
1 parent 6b2d026 commit ea92c45

File tree

2 files changed

+14
-1
lines changed

2 files changed

+14
-1
lines changed

pandas/tests/indexes/common.py

+11-1
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
import pytest
66

77
from pandas._libs import iNaT
8+
from pandas.compat.numpy import _is_numpy_dev
89
from pandas.errors import InvalidIndexError
910

1011
from pandas.core.dtypes.common import is_datetime64tz_dtype
@@ -417,7 +418,7 @@ def test_set_ops_error_cases(self, case, method, index):
417418
with pytest.raises(TypeError, match=msg):
418419
getattr(index, method)(case)
419420

420-
def test_intersection_base(self, index):
421+
def test_intersection_base(self, index, request):
421422
if isinstance(index, CategoricalIndex):
422423
return
423424

@@ -434,6 +435,15 @@ def test_intersection_base(self, index):
434435
# GH 10149
435436
cases = [klass(second.values) for klass in [np.array, Series, list]]
436437
for case in cases:
438+
# https://github.com/pandas-dev/pandas/issues/35481
439+
if (
440+
_is_numpy_dev
441+
and isinstance(case, Series)
442+
and isinstance(index, UInt64Index)
443+
):
444+
mark = pytest.mark.xfail(reason="gh-35481")
445+
request.node.add_marker(mark)
446+
437447
result = first.intersection(case)
438448
assert tm.equalContents(result, second)
439449

pandas/tests/indexing/test_loc.py

+3
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,8 @@
55
import numpy as np
66
import pytest
77

8+
from pandas.compat.numpy import _is_numpy_dev
9+
810
import pandas as pd
911
from pandas import DataFrame, Series, Timestamp, date_range
1012
import pandas._testing as tm
@@ -945,6 +947,7 @@ def test_loc_setitem_empty_append(self):
945947
df.loc[0, "x"] = expected.loc[0, "x"]
946948
tm.assert_frame_equal(df, expected)
947949

950+
@pytest.mark.xfail(_is_numpy_dev, reason="gh-35481")
948951
def test_loc_setitem_empty_append_raises(self):
949952
# GH6173, various appends to an empty dataframe
950953

0 commit comments

Comments
 (0)