def test_isCompleted_sub(self): todo = ToDo() self.assertEqual(todo.isCompleted(), False) todo.setCompleted() self.assertEqual(todo.isCompleted(), True) child = todo.addSubtodo(ToDo()) self.assertEqual(todo.isCompleted(), False) child.setCompleted() self.assertEqual(todo.isCompleted(), True) self.assertEqual(child.isCompleted(), True)
def test_isCompleted(self): todo = ToDo() self.assertEqual(todo.isCompleted(), False) todo.setCompleted() self.assertEqual(todo.isCompleted(), True)