diff options
author | Nicolas Goaziou <mail@nicolasgoaziou.fr> | 2019-03-10 18:22:05 +0100 |
---|---|---|
committer | Nicolas Goaziou <mail@nicolasgoaziou.fr> | 2019-03-10 18:22:05 +0100 |
commit | 589cfb74882e4dca03134fa8a4bbd36b96ca17b1 (patch) | |
tree | b3fcf4322c5d878667d75f7267ba122e8caffa42 | |
parent | dccccee7fc448c72ee003b75df07561b9e810ea9 (diff) | |
parent | 2216f4d2c71b31b11bb13ec13b312fe77b9de21a (diff) | |
download | org-mode-589cfb74882e4dca03134fa8a4bbd36b96ca17b1.tar.gz |
Merge branch 'maint'
-rw-r--r-- | testing/lisp/test-org-protocol.el | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/testing/lisp/test-org-protocol.el b/testing/lisp/test-org-protocol.el index fc76438..6ee368d 100644 --- a/testing/lisp/test-org-protocol.el +++ b/testing/lisp/test-org-protocol.el @@ -35,6 +35,16 @@ (let ((data (org-protocol-parse-parameters "url=abc&title=def" t))) (should (string= (plist-get data :url) "abc")) (should (string= (plist-get data :title) "def"))) + ;; Parse new-style complex links + (let* ((url (concat "template=p&" + "url=https%3A%2F%2Forgmode.org%2Forg.html%23capture-protocol&" + "title=The%20Org%20Manual&" + "body=9.4.2%20capture%20protocol")) + (data (org-protocol-parse-parameters url))) + (should (string= (plist-get data :template) "p")) + (should (string= (plist-get data :url) "https://orgmode.org/org.html#capture-protocol")) + (should (string= (plist-get data :title) "The Org Manual")) + (should (string= (plist-get data :body) "9.4.2 capture protocol"))) ;; Parse old-style links (let ((data (org-protocol-parse-parameters "abc/def" nil '(:url :title)))) (should (string= (plist-get data :url) "abc")) |