Tests: Add (heading)

This commit is contained in:
Adam Porter 2019-09-11 22:07:59 -05:00
parent f55fe7ef79
commit 9bc3138ff8

View file

@ -411,6 +411,16 @@ RESULTS should be a list of strings as returned by
(org-ql-expect ((habit)) (org-ql-expect ((habit))
'("Practice leaping tall buildings in a single bound"))) '("Practice leaping tall buildings in a single bound")))
(describe "(heading)"
(org-ql-it "with one argument"
(org-ql-expect ((heading "world"))
;; NOTE: This--correctly--does not match the "Skype with president of
;; Antarctica" heading, which has the tag ":world:" in its heading line.
'("Take over the world")))
(org-ql-it "with two arguments"
(org-ql-expect ((heading "Take over" "world"))
'("Take over the world"))))
(describe "(path)" (describe "(path)"
(org-ql-it "without arguments" (org-ql-it "without arguments"
(org-ql-expect ((path)) (org-ql-expect ((path))