@@ -126,12 +126,15 @@ def test_compare_scalar_interval_mixed_closed(self, op, closed, other_closed):
126
126
expected = self .elementwise_comparison (op , array , other )
127
127
tm .assert_numpy_array_equal (result , expected )
128
128
129
- def test_compare_scalar_na (self , op , array , nulls_fixture ):
129
+ def test_compare_scalar_na (self , op , array , nulls_fixture , request ):
130
130
result = op (array , nulls_fixture )
131
131
expected = self .elementwise_comparison (op , array , nulls_fixture )
132
132
133
- if nulls_fixture is pd .NA and array .dtype != pd .IntervalDtype ("int" ):
134
- pytest .xfail ("broken for non-integer IntervalArray; see GH 31882" )
133
+ if nulls_fixture is pd .NA and array .dtype != pd .IntervalDtype ("int64" ):
134
+ mark = pytest .mark .xfail (
135
+ reason = "broken for non-integer IntervalArray; see GH 31882"
136
+ )
137
+ request .node .add_marker (mark )
135
138
136
139
tm .assert_numpy_array_equal (result , expected )
137
140
@@ -207,13 +210,15 @@ def test_compare_list_like_object(self, op, array, other):
207
210
expected = self .elementwise_comparison (op , array , other )
208
211
tm .assert_numpy_array_equal (result , expected )
209
212
210
- def test_compare_list_like_nan (self , op , array , nulls_fixture ):
213
+ def test_compare_list_like_nan (self , op , array , nulls_fixture , request ):
211
214
other = [nulls_fixture ] * 4
212
215
result = op (array , other )
213
216
expected = self .elementwise_comparison (op , array , other )
214
217
215
- if nulls_fixture is pd .NA :
216
- pytest .xfail ("broken for non-integer IntervalArray; see GH 31882" )
218
+ if nulls_fixture is pd .NA and array .dtype .subtype != "i8" :
219
+ reason = "broken for non-integer IntervalArray; see GH 31882"
220
+ mark = pytest .mark .xfail (reason = reason )
221
+ request .node .add_marker (mark )
217
222
218
223
tm .assert_numpy_array_equal (result , expected )
219
224
0 commit comments