@@ -190,13 +190,14 @@ def test_series_constructor_scalar_with_index(self, data, dtype):
190
190
191
191
192
192
class TestReshaping (BaseJSON , base .BaseReshapingTests ):
193
- @pytest .mark .skip (reason = "Different definitions of NA" )
193
+ @pytest .mark .xfail (reason = "Different definitions of NA" )
194
194
def test_stack (self ):
195
195
"""
196
196
The test does .astype(object).stack(). If we happen to have
197
197
any missing values in `data`, then we'll end up with different
198
198
rows since we consider `{}` NA, but `.astype(object)` doesn't.
199
199
"""
200
+ super ().test_stack ()
200
201
201
202
@pytest .mark .xfail (reason = "dict for NA" )
202
203
def test_unstack (self , data , index ):
@@ -214,16 +215,18 @@ class TestIndex(BaseJSON, base.BaseIndexTests):
214
215
215
216
216
217
class TestMissing (BaseJSON , base .BaseMissingTests ):
217
- @pytest .mark .skip (reason = "Setting a dict as a scalar" )
218
+ @pytest .mark .xfail (reason = "Setting a dict as a scalar" )
218
219
def test_fillna_series (self ):
219
220
"""We treat dictionaries as a mapping in fillna, not a scalar."""
221
+ super ().test_fillna_series ()
220
222
221
- @pytest .mark .skip (reason = "Setting a dict as a scalar" )
223
+ @pytest .mark .xfail (reason = "Setting a dict as a scalar" )
222
224
def test_fillna_frame (self ):
223
225
"""We treat dictionaries as a mapping in fillna, not a scalar."""
226
+ super ().test_fillna_frame ()
224
227
225
228
226
- unhashable = pytest .mark .skip (reason = "Unhashable" )
229
+ unhashable = pytest .mark .xfail (reason = "Unhashable" )
227
230
228
231
229
232
class TestReduce (base .BaseNoReduceTests ):
@@ -233,16 +236,16 @@ class TestReduce(base.BaseNoReduceTests):
233
236
class TestMethods (BaseJSON , base .BaseMethodsTests ):
234
237
@unhashable
235
238
def test_value_counts (self , all_data , dropna ):
236
- pass
239
+ super (). test_value_counts ( all_data , dropna )
237
240
238
241
@unhashable
239
242
def test_value_counts_with_normalize (self , data ):
240
- pass
243
+ super (). test_value_counts_with_normalize ( data )
241
244
242
245
@unhashable
243
246
def test_sort_values_frame (self ):
244
247
# TODO (EA.factorize): see if _values_for_factorize allows this.
245
- pass
248
+ super (). test_sort_values_frame ()
246
249
247
250
@pytest .mark .parametrize ("ascending" , [True , False ])
248
251
def test_sort_values (self , data_for_sorting , ascending , sort_by_key ):
@@ -256,45 +259,46 @@ def test_sort_values_missing(
256
259
data_missing_for_sorting , ascending , sort_by_key
257
260
)
258
261
259
- @pytest .mark .skip (reason = "combine for JSONArray not supported" )
262
+ @pytest .mark .xfail (reason = "combine for JSONArray not supported" )
260
263
def test_combine_le (self , data_repeated ):
261
- pass
264
+ super (). test_combine_le ( data_repeated )
262
265
263
- @pytest .mark .skip (reason = "combine for JSONArray not supported" )
266
+ @pytest .mark .xfail (reason = "combine for JSONArray not supported" )
264
267
def test_combine_add (self , data_repeated ):
265
- pass
268
+ super (). test_combine_add ( data_repeated )
266
269
267
- @pytest .mark .skip (reason = "combine for JSONArray not supported" )
270
+ @pytest .mark .xfail (reason = "combine for JSONArray not supported" )
268
271
def test_combine_first (self , data ):
269
- pass
272
+ super (). test_combine_first ( data )
270
273
271
274
@unhashable
272
275
def test_hash_pandas_object_works (self , data , kind ):
273
276
super ().test_hash_pandas_object_works (data , kind )
274
277
275
- @pytest .mark .skip (reason = "broadcasting error" )
278
+ @pytest .mark .xfail (reason = "broadcasting error" )
276
279
def test_where_series (self , data , na_value ):
277
280
# Fails with
278
281
# *** ValueError: operands could not be broadcast together
279
282
# with shapes (4,) (4,) (0,)
280
283
super ().test_where_series (data , na_value )
281
284
282
- @pytest .mark .skip (reason = "Can't compare dicts." )
285
+ @pytest .mark .xfail (reason = "Can't compare dicts." )
283
286
def test_searchsorted (self , data_for_sorting ):
284
287
super ().test_searchsorted (data_for_sorting )
285
288
286
- @pytest .mark .skip (reason = "Can't compare dicts." )
289
+ @pytest .mark .xfail (reason = "Can't compare dicts." )
287
290
def test_equals (self , data , na_value , as_series ):
288
- pass
291
+ super (). test_equals ( data , na_value , as_series )
289
292
290
293
291
294
class TestCasting (BaseJSON , base .BaseCastingTests ):
292
- @pytest .mark .skip (reason = "failing on np.array(self, dtype=str)" )
295
+ @pytest .mark .xfail (reason = "failing on np.array(self, dtype=str)" )
293
296
def test_astype_str (self ):
294
297
"""This currently fails in NumPy on np.array(self, dtype=str) with
295
298
296
299
*** ValueError: setting an array element with a sequence
297
300
"""
301
+ super ().test_astype_str ()
298
302
299
303
300
304
# We intentionally don't run base.BaseSetitemTests because pandas'
@@ -310,6 +314,7 @@ def test_groupby_extension_transform(self):
310
314
I think this is what we want, i.e. `.name` should be the original
311
315
values, and not the values for factorization.
312
316
"""
317
+ super ().test_groupby_extension_transform ()
313
318
314
319
@unhashable
315
320
def test_groupby_extension_apply (self ):
@@ -322,20 +327,23 @@ def test_groupby_extension_apply(self):
322
327
I suspect that once we support Index[ExtensionArray],
323
328
we'll be able to dispatch unique.
324
329
"""
330
+ super ().test_groupby_extension_apply ()
325
331
326
332
@unhashable
327
333
def test_groupby_extension_agg (self ):
328
334
"""
329
335
This fails when we get to tm.assert_series_equal when left.index
330
336
contains dictionaries, which are not hashable.
331
337
"""
338
+ super ().test_groupby_extension_agg ()
332
339
333
340
@unhashable
334
341
def test_groupby_extension_no_sort (self ):
335
342
"""
336
343
This fails when we get to tm.assert_series_equal when left.index
337
344
contains dictionaries, which are not hashable.
338
345
"""
346
+ super ().test_groupby_extension_no_sort ()
339
347
340
348
@pytest .mark .xfail (reason = "GH#39098: Converts agg result to object" )
341
349
def test_groupby_agg_extension (self , data_for_grouping ):
@@ -354,10 +362,11 @@ def test_add_series_with_extension_array(self, data):
354
362
with pytest .raises (TypeError , match = "unsupported" ):
355
363
ser + data
356
364
365
+ @pytest .mark .xfail (reason = "not implemented" )
357
366
def test_divmod_series_array (self ):
358
367
# GH 23287
359
368
# skipping because it is not implemented
360
- pass
369
+ super (). test_divmod_series_array ()
361
370
362
371
def _check_divmod_op (self , s , op , other , exc = NotImplementedError ):
363
372
return super ()._check_divmod_op (s , op , other , exc = TypeError )
0 commit comments