Exemplo n.º 1
0
def test_batches_size_must_be_strictly_positive(size):
    with pytest.raises(ValueError):
        list(batches([1, 2, 3], size=size))
Exemplo n.º 2
0
def test_batches(items, size, output):
    # type: (list, int, list) -> None
    assert list(batches(items, size=size)) == output