MCPcopy Index your code
hub / github.com/pydata/xarray / test_NumpyIndexingAdapter

Method test_NumpyIndexingAdapter

xarray/tests/test_variable.py:2983–2991  ·  view source on GitHub ↗
(self, load_async)

Source from the content-addressed store, hash-verified

2981 @pytest.mark.asyncio
2982 @pytest.mark.parametrize("load_async", [True, False])
2983 async def test_NumpyIndexingAdapter(self, load_async):
2984 v = Variable(dims=("x", "y"), data=NumpyIndexingAdapter(self.d))
2985 await self.check_orthogonal_indexing(v, load_async)
2986 await self.check_vectorized_indexing(v, load_async)
2987 # could not doubly wrapping
2988 with pytest.raises(TypeError, match=r"NumpyIndexingAdapter only wraps "):
2989 v = Variable(
2990 dims=("x", "y"), data=NumpyIndexingAdapter(NumpyIndexingAdapter(self.d))
2991 )
2992
2993 def test_extension_array_duck_array(self):
2994 lazy = LazilyIndexedArray(self.cat)

Callers

nothing calls this directly

Calls 4

VariableClass · 0.90

Tested by

no test coverage detected