def test_reduce_2(): stream = Stream([1, 2, 3]) r = stream.reduce(lambda x, y: x + y, 10) assert r == 16
def test_reduce_1(): stream = Stream([1, 2, 3]) r = stream.reduce(lambda x, y: x + y) assert r == 6