Пример #1
0
def test_chunk_invalid(n):
    with pytest.raises(ValueError):
        list(utils.chunk([], n))
Пример #2
0
def test_chunk_invalid(n):
    with pytest.raises(ValueError):
        list(utils.chunk([], n))
Пример #3
0
def test_chunk(elems, n, expected):
    assert list(utils.chunk(elems, n)) == expected
Пример #4
0
def test_chunk(elems, n, expected):
    assert list(utils.chunk(elems, n)) == expected