@@ -250,7 +250,7 @@ def f(a, v):
250
250
assert_raises ((ValueError , RuntimeError ), f , a , [1 , 2 , 3 ])
251
251
assert_raises ((ValueError , RuntimeError ), f , a [:1 ], [1 , 2 , 3 ])
252
252
253
- @pytest .mark .xfail ("torch does not support object dtype" )
253
+ @pytest .mark .xfail (reason = "torch does not support object dtype" )
254
254
def test_boolean_assignment_needs_api (self ):
255
255
# See also gh-7666
256
256
# This caused a segfault on Python 2 due to the GIL not being
@@ -332,7 +332,7 @@ def test_uncontiguous_subspace_assignment(self):
332
332
333
333
assert_equal (a , b )
334
334
335
- @pytest .mark .xfail ("torch does not limit dims to 32" )
335
+ @pytest .mark .xfail (reason = "torch does not limit dims to 32" )
336
336
def test_too_many_fancy_indices_special_case (self ):
337
337
# Just documents behaviour, this is a small limitation.
338
338
a = np .ones ((1 ,) * 32 ) # 32 is NPY_MAXDIMS
@@ -390,6 +390,7 @@ def test_trivial_fancy_not_possible(self):
390
390
res [3 ] = - 1
391
391
assert_array_equal (a , res )
392
392
393
+ @pytest .mark .xfail (reason = "XXX: wrapping view stuff is TBD" )
393
394
def test_nonbaseclass_values (self ):
394
395
class SubClass (np .ndarray ):
395
396
def __array_finalize__ (self , old ):
@@ -411,6 +412,7 @@ def __array_finalize__(self, old):
411
412
a [...] = s
412
413
assert_ ((a == 1 ).all ())
413
414
415
+ @pytest .mark .xfail (reason = "XXX: wrapping view stuff is TBD" )
414
416
def test_array_like_values (self ):
415
417
# Similar to the above test, but use a memoryview instead
416
418
a = np .zeros ((5 , 5 ))
@@ -496,6 +498,7 @@ def test_small_regressions(self):
496
498
if HAS_REFCOUNT :
497
499
assert_equal (sys .getrefcount (np .dtype (np .intp )), refcount )
498
500
501
+ @pytest .mark .xfail (reason = "XXX: wrapping view stuff is TBD" )
499
502
def test_unaligned (self ):
500
503
v = (np .zeros (64 , dtype = np .int8 ) + ord ('a' ))[1 :- 7 ]
501
504
d = v .view (np .dtype ("S8" ))
@@ -603,6 +606,8 @@ def test_too_many_advanced_indices(self, index, num, original_ndim):
603
606
with pytest .raises (IndexError ):
604
607
arr [(index ,) * num ] = 1.
605
608
609
+
610
+ @pytest .mark .xfail (reason = "XXX: wrapping view stuff is TBD" )
606
611
@pytest .mark .skipif (IS_WASM , reason = "no threading" )
607
612
def test_structured_advanced_indexing (self ):
608
613
# Test that copyswap(n) used by integer array indexing is threadsafe
@@ -711,6 +716,7 @@ def test_broadcast_subspace(self):
711
716
assert_ ((a [::- 1 ] == v ).all ())
712
717
713
718
719
+ @pytest .mark .xfail (reason = "XXX: wrapping view stuff is TBD" )
714
720
class TestSubclasses :
715
721
def test_basic (self ):
716
722
# Test that indexing in various ways produces SubClass instances,
@@ -1186,6 +1192,7 @@ def _check_single_index(self, arr, index):
1186
1192
def _compare_index_result (self , arr , index , mimic_get , no_copy ):
1187
1193
"""Compare mimicked result to indexing result.
1188
1194
"""
1195
+ pytest .xfail ("XXX: wrapping view stuff is TBD" )
1189
1196
arr = arr .copy ()
1190
1197
indexed_arr = arr [index ]
1191
1198
assert_array_equal (indexed_arr , mimic_get )
0 commit comments