Esempio n. 1
0
def test_doall():
    s = []
    fn_calls = repeatedly(partial(_side_effecter, s), 5)
    assert doall(fn_calls) == list(fn_calls)
    assert s == [0, 0, 0, 0, 0]
Esempio n. 2
0
def test_dorun():
    s = []
    assert dorun(repeatedly(partial(_side_effecter, s), 5)) is None
    assert s == [0, 0, 0, 0, 0]