예제 #1
0
def test_batch_single():
    for batch_size in range(1, 10):
        batched = tuple(main.batch([1], batch_size=batch_size))
        assert batched == ((1,),)
예제 #2
0
def test_batch_single():
    for batch_size in range(1, 10):
        batched = tuple(main.batch([1], batch_size=batch_size))
        assert batched == ((1, ), )
예제 #3
0
def test_batch_empty():
    for batch_size in range(1, 10):
        assert len(
            list(main.batch([], batch_size=batch_size))) == 0
예제 #4
0
def test_batch_empty():
    for batch_size in range(1, 10):
        assert len(list(main.batch([], batch_size=batch_size))) == 0