diff options
author | Kyle Meyer <kyle@kyleam.com> | 2017-03-03 00:13:59 -0500 |
---|---|---|
committer | Kyle Meyer <kyle@kyleam.com> | 2017-03-03 01:29:07 -0500 |
commit | 2cda5ae7d6141c06fc72e4c1b7f9f792cb8c2e05 (patch) | |
tree | 98b72993da9a9732b021764d610cd29bc62a7d93 /test-org-link-edit.el | |
parent | ae8e918c873febd58abfc332ebf8f59448e8fff4 (diff) | |
download | org-link-edit-2cda5ae7d6141c06fc72e4c1b7f9f792cb8c2e05.tar.gz |
Add org-link-edit-transport-next-link command
Diffstat (limited to 'test-org-link-edit.el')
-rw-r--r-- | test-org-link-edit.el | 44 |
1 files changed, 44 insertions, 0 deletions
diff --git a/test-org-link-edit.el b/test-org-link-edit.el index 4f006e7..7e4d2af 100644 --- a/test-org-link-edit.el +++ b/test-org-link-edit.el @@ -511,6 +511,50 @@ website" (buffer-string))))) +;;; Transport + +(ert-deftest test-org-link-edit/transport-next-link () + "Test `org-link-edit-transport-next-link'." + (should + (string= "Here is \[\[http://orgmode.org/\]\[Org's\]\] website " + (org-test-with-temp-text + "Here is <point>Org's website http://orgmode.org/" + (org-link-edit-transport-next-link) + (buffer-string)))) + (should + (string= " Here is \[\[http://orgmode.org/\]\[Org's\]\] website" + (org-test-with-temp-text + "http://orgmode.org/ Here is <point>Org's website" + (org-link-edit-transport-next-link 'previous) + (buffer-string)))) + (should + (string= "\[\[http://orgmode.org/\]\[Here is Org's\]\] website " + (org-test-with-temp-text + "Here is Org's<point> website http://orgmode.org/" + (org-link-edit-transport-next-link + nil (point-min) (point)) + (buffer-string)))) + (should + (string= " Here is \[\[http://orgmode.org/\]\[Org's website\]\]" + (org-test-with-temp-text + "http://orgmode.org/ Here is <point>Org's website" + (org-link-edit-transport-next-link + 'previous (point) (point-max)) + (buffer-string)))) + (should-error + (org-test-with-temp-text + "Here is Org's website http://orgmode.org/<point>" + (org-link-edit-transport-next-link) + (buffer-string))) + (should-error + (org-test-with-temp-text + "Here is Org's website <point>http://orgmode.org/" + (org-link-edit-transport-next-link + nil (point-min) (point)) + (buffer-string))) + ) + + ;;; Other (ert-deftest test-org-link-edit/on-link-p () |