MCPcopy Create free account
hub / github.com/dask/dask / test_normalize_index

Function test_normalize_index

dask/array/tests/test_slicing.py:850–856  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

848
849
850def test_normalize_index():
851 assert normalize_index((Ellipsis, None), (10,)) == (slice(None), None)
852 assert normalize_index(5, (np.nan,)) == (5,)
853 assert normalize_index(-5, (np.nan,)) == (-5,)
854 (result,) = normalize_index([-5, -2, 1], (np.nan,))
855 assert result.tolist() == [-5, -2, 1]
856 assert normalize_index(slice(-5, -2), (np.nan,)) == (slice(-5, -2),)
857
858
859def test_take_semi_sorted():

Callers

nothing calls this directly

Calls 1

normalize_indexFunction · 0.90

Tested by

no test coverage detected