def test_rechunk_internals_1():
    new = cumdims_label(((1,1,2),(1,5,1)),'n')
    old = cumdims_label(((4, ),(1,) * 5),'o')
    breaks = tuple(_breakpoints(o, n) for o, n in zip(old, new))
    answer = (('o', 0), ('n', 0), ('n', 1), ('n', 2), ('o', 4), ('n', 4))
    assert breaks[0] == answer
    answer2 = (('o', 0),
                 ('n', 0),
                 ('o', 1),
                 ('n', 1),
                 ('o', 2),
                 ('o', 3),
                 ('o', 4),
                 ('o', 5),
                 ('n', 6),
                 ('n', 7))
    assert breaks[1] == answer2
    i1d = [_intersect_1d(b) for b in breaks]
    answer3 = (((0, slice(0, 1, None)),),
             ((0, slice(1, 2, None)),),
             ((0, slice(2, 4, None)),))
    assert i1d[0] == answer3
    answer4 = (((0, slice(0, 1, None)),),
             ((1, slice(0, 1, None)),
              (2, slice(0, 1, None)),
              (3, slice(0, 1, None)),
              (4, slice(0, 1, None)),
              (5, slice(0, 1, None))),
             ((5, slice(1, 2, None)),))
    assert i1d[1] == answer4
Death is upon us
dataset/ETHPy150Open dask/dask/dask/array/tests/test_rechunk.py/test_rechunk_internals_1--crossover with--dataset/ETHPy150Open tariqdaouda/Mariana/Mariana/candies.py/fatal