Skip to content

Commit ea679a8

Browse files
committed
Skip the view related tests
1 parent 9b1fce1 commit ea679a8

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

torch_np/tests/numpy_tests/core/test_indexing.py

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -393,7 +393,7 @@ def test_trivial_fancy_not_possible(self):
393393
res[3] = -1
394394
assert_array_equal(a, res)
395395

396-
@pytest.mark.xfail(reason="XXX: wrapping view stuff is TBD")
396+
@pytest.mark.skip(reason="torch does not support subclassing")
397397
def test_nonbaseclass_values(self):
398398
class SubClass(np.ndarray):
399399
def __array_finalize__(self, old):
@@ -415,7 +415,7 @@ def __array_finalize__(self, old):
415415
a[...] = s
416416
assert_((a == 1).all())
417417

418-
@pytest.mark.xfail(reason="XXX: wrapping view stuff is TBD")
418+
@pytest.mark.skip(reason="torch does not support subclassing")
419419
def test_array_like_values(self):
420420
# Similar to the above test, but use a memoryview instead
421421
a = np.zeros((5, 5))
@@ -510,7 +510,7 @@ def test_small_regressions(self):
510510
if HAS_REFCOUNT:
511511
assert_equal(sys.getrefcount(np.dtype(np.intp)), refcount)
512512

513-
@pytest.mark.xfail(reason="XXX: wrapping view stuff is TBD")
513+
@pytest.mark.skip(reason="torch does not support subclassing")
514514
def test_unaligned(self):
515515
v = (np.zeros(64, dtype=np.int8) + ord('a'))[1:-7]
516516
d = v.view(np.dtype("S8"))
@@ -624,7 +624,7 @@ def test_too_many_advanced_indices(self, index, num, original_ndim):
624624
arr[(index,) * num] = 1.
625625

626626

627-
@pytest.mark.xfail(reason="XXX: wrapping view stuff is TBD")
627+
@pytest.mark.skip(reason="torch does not support subclassing")
628628
@pytest.mark.skipif(IS_WASM, reason="no threading")
629629
def test_structured_advanced_indexing(self):
630630
# Test that copyswap(n) used by integer array indexing is threadsafe
@@ -743,7 +743,7 @@ def test_broadcast_subspace(self):
743743
assert_((a[::-1] == v).all())
744744

745745

746-
@pytest.mark.xfail(reason="XXX: wrapping view stuff is TBD")
746+
@pytest.mark.skip(reason="torch does not support subclassing")
747747
class TestSubclasses:
748748
def test_basic(self):
749749
# Test that indexing in various ways produces SubClass instances,
@@ -1225,7 +1225,7 @@ def _check_single_index(self, arr, index):
12251225
def _compare_index_result(self, arr, index, mimic_get, no_copy):
12261226
"""Compare mimicked result to indexing result.
12271227
"""
1228-
pytest.xfail("XXX: wrapping view stuff is TBD")
1228+
pytest.skip("torch does not support subclassing")
12291229
arr = arr.copy()
12301230
indexed_arr = arr[index]
12311231
assert_array_equal(indexed_arr, mimic_get)

0 commit comments

Comments
 (0)