MCPcopy
hub / github.com/dask/dask / test_getter

Function test_getter

dask/array/tests/test_array_core.py:2807–2812  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

2805
2806@pytest.mark.filterwarnings("ignore:the matrix subclass")
2807def test_getter():
2808 assert type(getter(np.matrix([[1]]), 0)) is np.ndarray
2809 assert type(getter(np.matrix([[1]]), 0, asarray=False)) is np.matrix
2810 assert_eq(getter([1, 2, 3, 4, 5], slice(1, 4)), np.array([2, 3, 4]))
2811
2812 assert_eq(getter(np.arange(5), (None, slice(None, None))), np.arange(5)[None, :])
2813
2814
2815def test_size():

Callers

nothing calls this directly

Calls 3

getterFunction · 0.90
assert_eqFunction · 0.90
arangeMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…