本文整理汇总了Python中topydo.lib.TodoBase.TodoBase.is_completed方法的典型用法代码示例。如果您正苦于以下问题:Python TodoBase.is_completed方法的具体用法?Python TodoBase.is_completed怎么用?Python TodoBase.is_completed使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类topydo.lib.TodoBase.TodoBase
的用法示例。
在下文中一共展示了TodoBase.is_completed方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: test_completion5
# 需要导入模块: from topydo.lib.TodoBase import TodoBase [as 别名]
# 或者: from topydo.lib.TodoBase.TodoBase import is_completed [as 别名]
def test_completion5(self):
"""
A todo item with an invalid completion date is still considered as
completed, but without a creation date.
"""
todo = TodoBase("x 2017-06-31 Invalid date")
self.assertTrue(todo.is_completed())
self.assertIsNone(todo.completion_date())
示例2: test_completion4
# 需要导入模块: from topydo.lib.TodoBase import TodoBase [as 别名]
# 或者: from topydo.lib.TodoBase.TodoBase import is_completed [as 别名]
def test_completion4(self):
""" A completed todo must start with an x followed by a date. """
todo = TodoBase("X 2014-06-14 Not complete")
self.assertFalse(todo.is_completed())
示例3: test_completion2
# 需要导入模块: from topydo.lib.TodoBase import TodoBase [as 别名]
# 或者: from topydo.lib.TodoBase.TodoBase import is_completed [as 别名]
def test_completion2(self):
todo = TodoBase("xx Important xx")
self.assertFalse(todo.is_completed())
示例4: test_completion1
# 需要导入模块: from topydo.lib.TodoBase import TodoBase [as 别名]
# 或者: from topydo.lib.TodoBase.TodoBase import is_completed [as 别名]
def test_completion1(self):
todo = TodoBase("x 2014-06-09 Foo")
self.assertTrue(todo.is_completed())