X-Git-Url: https://git.madduck.net/etc/taskwarrior.git/blobdiff_plain/6adf5e34ed35f8b5d9975867c92096f4b9bc080f..4c0d71c0c2a8b190249416b29b310f4afcab755b:/tasklib/tests.py diff --git a/tasklib/tests.py b/tasklib/tests.py index 76a9514..fe37e01 100644 --- a/tasklib/tests.py +++ b/tasklib/tests.py @@ -240,6 +240,22 @@ class TaskTest(TasklibTest): t2 = self.tw.tasks.get(uuid=t1['uuid']) self.assertEqual(t1.__hash__(), t2.__hash__()) + def test_adding_task_with_priority(self): + t = Task(self.tw, description="test task", priority="M") + t.save() + + def test_removing_priority_with_none(self): + t = Task(self.tw, description="test task", priority="L") + t.save() + + # Remove the priority mark + t['priority'] = None + t.save() + + # Assert that priority is not there after saving + self.assertEqual(t['priority'], None) + + class AnnotationTest(TasklibTest): def setUp(self):