diff options
Diffstat (limited to 'test/lisp/subr-tests.el')
-rw-r--r-- | test/lisp/subr-tests.el | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/test/lisp/subr-tests.el b/test/lisp/subr-tests.el index 06db8f5c902..0023680738d 100644 --- a/test/lisp/subr-tests.el +++ b/test/lisp/subr-tests.el @@ -400,5 +400,15 @@ See https://debbugs.gnu.org/cgi/bugreport.cgi?bug=19350." (should (equal subr-tests--hook '(f5 f10 f9 f6 f2 f1 f4 f3 f7 f8))) ) +(ert-deftest ignore-error-tests () + (should (equal (ignore-error (end-of-file) + (read "")) + nil)) + (should (equal (ignore-error end-of-file + (read "")) + nil)) + (should-error (ignore-error foo + (read "")))) + (provide 'subr-tests) ;;; subr-tests.el ends here |