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

Function test_is_empty_numpy_array

dask/tests/test_utils.py:961–967  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

959
960
961def test_is_empty_numpy_array():
962 np = pytest.importorskip("numpy")
963
964 assert is_empty(np.array([])) is True
965 assert is_empty(np.array([1, 2])) is False
966 # len() == 3 → not empty even though one dimension is 0
967 assert is_empty(np.empty((3, 0))) is False
968
969
970def test_is_empty_fake_sparse_like_object():

Callers

nothing calls this directly

Calls 2

is_emptyFunction · 0.90
emptyMethod · 0.45

Tested by

no test coverage detected