def test_push(self): myStack = Stack() myStack.push(5) self.assertEqual(myStack.topElement(), 5)
def test_pop(self): myStack = Stack() myStack.push(10) self.assertEqual(myStack.pop().data, 10)
def test_isNotEmpty(self): myStack = Stack() myStack.push(10) self.assertFalse(myStack.isEmpty())
def test_topElement(self): myStack = Stack() myStack.push(10) self.assertEqual(myStack.topElement(), 10)