diff options
Diffstat (limited to 'test')
-rw-r--r-- | test/emacs-hnreader-test.el | 11 | ||||
-rw-r--r-- | test/test-helper.el | 15 |
2 files changed, 26 insertions, 0 deletions
diff --git a/test/emacs-hnreader-test.el b/test/emacs-hnreader-test.el new file mode 100644 index 0000000..a2d40d6 --- /dev/null +++ b/test/emacs-hnreader-test.el @@ -0,0 +1,11 @@ +;;; emacs-hnreader-test.el --- Tests for emacs-hnreader +(ert-deftest-async test/promise-dom (done) + (promise-done + (promise-chain + (hnreader--promise-dom "https://www.google.com") + (then (lambda (result) + (should (listp result)) + ;; (message "%s" result) + (funcall done))) + (promise-catch done)))) +;;; emacs-hnreader-test.el ends here diff --git a/test/test-helper.el b/test/test-helper.el new file mode 100644 index 0000000..c0119bf --- /dev/null +++ b/test/test-helper.el @@ -0,0 +1,15 @@ +;;; test-helper.el --- Helpers for emacs-hnreader-test.el +(require 'f) +(require 'ert-async) + +(defvar root-test-path + (f-dirname (f-this-file))) + +(defvar root-code-path + (f-parent root-test-path)) + +(add-to-list 'load-path root-code-path) + +(require 'hnreader) + +;;; test-helper.el ends here |