Add unit test to test parsing of the id on newly created tasks
This commit is contained in:
parent
a19eebacd0
commit
02af750b16
1 changed files with 6 additions and 0 deletions
|
@ -18,5 +18,11 @@
|
||||||
(should (string= (aref (alist-get 'tags task) 0) "emacs"))
|
(should (string= (aref (alist-get 'tags task) 0) "emacs"))
|
||||||
(should (string= (alist-get 'description task) "Write test suite for taskwarrior.el (using ERT)"))))
|
(should (string= (alist-get 'description task) "Write test suite for taskwarrior.el (using ERT)"))))
|
||||||
|
|
||||||
|
(ert-deftest taskwarrior-parse-task-id ()
|
||||||
|
(should (string= (taskwarrior--parse-created-task-id "Created task 9.") "9"))
|
||||||
|
(should (string= (taskwarrior--parse-created-task-id "Created task 1000.") "1000"))
|
||||||
|
(should (string= (taskwarrior--parse-created-task-id "Some invalid input") nil)))
|
||||||
|
|
||||||
|
|
||||||
(provide 'taskwarrior-test)
|
(provide 'taskwarrior-test)
|
||||||
;;; taskwarrior-test.el ends here
|
;;; taskwarrior-test.el ends here
|
||||||
|
|
Loading…
Reference in a new issue