Polish set of stacks solution

This commit is contained in:
Donne Martin
2016-02-21 16:21:37 -05:00
parent 7222f71f59
commit d9b2d7144e
2 changed files with 23 additions and 31 deletions

View File

@@ -5,8 +5,7 @@ class TestSetOfStacks(object):
def test_set_of_stacks(self):
print('Test: Push on an empty stack')
capacity = 2
stacks = SetOfStacks(capacity)
stacks = SetOfStacks(capacity=2)
stacks.push(3)
print('Test: Push on a non-empty stack')
@@ -15,7 +14,7 @@ class TestSetOfStacks(object):
print('Test: Push on a capacity stack to create a new one')
stacks.push('a')
print('Test: Pop on a one element stack to destroy it')
print('Test: Pop on a stack to destroy it')
assert_equal(stacks.pop(), 'a')
print('Test: Pop general case')