Skip to content

Commit 2c28c2e

Browse files
committed
test_vendor
1 parent 9d197ed commit 2c28c2e

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

vendor_tests/test_vendor.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
from typing import Any
44

5-
import array_api_strict as xp
5+
import numpy as xp
66
from numpy.testing import assert_array_equal
77

88

@@ -31,19 +31,19 @@ def test_vendor_compat():
3131
)
3232

3333
x = xp.asarray([1, 2, 3])
34-
assert array_namespace(x) is xp
34+
assert "array_api_compat.numpy" in array_namespace(x).__name__
3535
to_device(x, device(x))
3636
assert is_array_api_obj(x)
37-
assert is_array_api_strict_namespace(xp)
37+
assert not is_array_api_strict_namespace(xp)
3838
assert not is_cupy_array(x)
3939
assert not is_cupy_namespace(xp)
4040
assert not is_dask_array(x)
4141
assert not is_dask_namespace(xp)
4242
assert not is_jax_array(x)
4343
assert not is_jax_namespace(xp)
4444
assert not is_lazy_array(x)
45-
assert not is_numpy_array(x)
46-
assert not is_numpy_namespace(xp)
45+
assert is_numpy_array(x)
46+
assert is_numpy_namespace(xp)
4747
assert not is_pydata_sparse_array(x)
4848
assert not is_pydata_sparse_namespace(xp)
4949
assert not is_torch_array(x)

0 commit comments

Comments
 (0)