emacs-ipython-notebook/test/test-ein-ac.el
John Miller 9d5309af59 Trying something new with testing.
Let's do this with ert-runner instead of python. Maybe it will work for once.
2018-02-27 14:38:13 -06:00

17 lines
586 B
EmacsLisp

(eval-when-compile (require 'cl))
(require 'ert)
(require 'ein-ac)
(require 'ein-testing-kernel)
(ert-deftest ein:ac-set-document ()
(let ((string "candidate string"))
(should-not (get-text-property 0 'document string))
(ein:testing-kernel-construct-help-string-loop
(lambda (content result)
(ein:ac-set-document string content '-not-used-)
(let ((props (text-properties-at 0 string)))
;; document property may be nil, but must be set.
(should (member 'document props))
(should (equal (plist-get props 'document) result)))))))