rich/tests/test_stack.py

12 lines
207 B
Python
Raw Normal View History

2019-12-24 12:51:31 +00:00
from rich._stack import Stack
def test_stack():
stack = Stack()
stack.push("foo")
stack.push("bar")
assert stack.top == "bar"
assert stack.pop() == "bar"
assert stack.top == "foo"