org-mode/testing/lisp/test-org-html.el
Bastien Guerry ecd0562c5f Fix the master branch.
I started from the 78ec8e commit then cherry-picked and squashed
commits that have been done in master since then, except the bad
commits that overwrote the tree (in master) with the tree in maint.

This commit also bumps the version number to 7.8.06.

The only "fix" that was made between 78ec8e and the previous commit
is e0072f which has been reported to break stuff.
2012-03-19 22:01:29 +01:00

33 lines
884 B
EmacsLisp

;;; test-org-html.el
;; Copyright (c) ߛ David Maus
;; Authors: David Maus
;; Released under the GNU General Public License version 3
;; see: http://www.gnu.org/licenses/gpl-3.0.html
;;;; Comments:
;; Template test file for Org-mode tests
;;; Code:
(unless (featurep 'org-html)
(signal 'missing-test-dependency "Support for Org-html"))
(defmacro org-test-html/export-link (name link expected &optional desc opt-plist)
`(ert-deftest ,(intern (concat "test-org-html/export-link/" name)) ()
,(or desc name)
(should
(string=
(org-test-strip-text-props
(org-html-handle-links ,link ,opt-plist))
,expected))))
(org-test-html/export-link "mailto" "[[mailto:john@example.tld]]"
"<a href=\"mailto:john@example.tld\">mailto:john@example.tld</a>"
"mailto: link without description")
(provide 'test-org-html)
;;; test-org-html.el ends here