diff options
Diffstat (limited to 'test/src/lread-tests.el')
-rw-r--r-- | test/src/lread-tests.el | 10 |
1 files changed, 1 insertions, 9 deletions
diff --git a/test/src/lread-tests.el b/test/src/lread-tests.el index dac8f95bc4d..be685fe999f 100644 --- a/test/src/lread-tests.el +++ b/test/src/lread-tests.el @@ -119,14 +119,6 @@ (should (equal '(#s(foo) #s(foo)) (read "(#1=#s(foo) #1#)")))) -(defmacro lread-tests--with-temp-file (file-name-var &rest body) - (declare (indent 1)) - (cl-check-type file-name-var symbol) - `(let ((,file-name-var (make-temp-file "emacs"))) - (unwind-protect - (progn ,@body) - (delete-file ,file-name-var)))) - (defun lread-tests--last-message () (with-current-buffer "*Messages*" (save-excursion @@ -137,7 +129,7 @@ (ert-deftest lread-tests--unescaped-char-literals () "Check that loading warns about unescaped character literals (Bug#20852)." - (lread-tests--with-temp-file file-name + (ert-with-temp-file file-name (write-region "?) ?( ?; ?\" ?[ ?]" nil file-name) (should (equal (load file-name nil :nomessage :nosuffix) t)) (should (equal (lread-tests--last-message) |