Пример #1
0
def test_pop():
    state = State(stack=[1, 2])
    state.pop()
    assert state.stack == [1]
Пример #2
0
def test_pop_empty_stack():
    state = State()
    with pytest.raises(exc.StackError):
        state.pop()