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

Function test_ndeepmap

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

Source from the content-addressed store, hash-verified

483
484
485def test_ndeepmap():
486 L = 1
487 assert ndeepmap(0, inc, L) == 2
488
489 L = [1]
490 assert ndeepmap(0, inc, L) == 2
491
492 L = [1, 2, 3]
493 assert ndeepmap(1, inc, L) == [2, 3, 4]
494
495 L = [[1, 2], [3, 4]]
496 assert ndeepmap(2, inc, L) == [[2, 3], [4, 5]]
497
498 L = [[[1, 2], [3, 4, 5]], [[6], []]]
499 assert ndeepmap(3, inc, L) == [[[2, 3], [4, 5, 6]], [[7], []]]
500
501
502def test_ensure_dict():

Callers

nothing calls this directly

Calls 1

ndeepmapFunction · 0.90

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…