aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--evil-test-helpers.el6
-rw-r--r--evil-tests.el6
2 files changed, 4 insertions, 8 deletions
diff --git a/evil-test-helpers.el b/evil-test-helpers.el
index c70ea21..03e5cf3 100644
--- a/evil-test-helpers.el
+++ b/evil-test-helpers.el
@@ -383,10 +383,6 @@ is executed at the end."
(goto-char (overlay-end ,overlay))
(evil-test-text (or ,end-string ,string) nil nil ,after-predicate))))
-(defun evil-temp-filename ()
- "Return an appropriate temporary filename."
- (make-temp-file "evil-test"))
-
(defmacro evil-with-temp-file (file-var content &rest body)
"Create a temp file with CONTENT and bind its name to FILE-VAR within BODY.
FILE-VAR must be a symbol which contains the name of the
@@ -398,7 +394,7 @@ while the temporary file exists. The temporary file is deleted at
the end of the execution of BODY."
(declare (indent 2)
(debug (symbolp form body)))
- `(let ((,file-var (evil-temp-filename)))
+ `(let ((,file-var (make-temp-file "evil-test")))
(with-temp-file ,file-var
,(if (stringp content)
`(insert ,content)
diff --git a/evil-tests.el b/evil-tests.el
index 2ab00d4..e0e3fbf 100644
--- a/evil-tests.el
+++ b/evil-tests.el
@@ -7445,7 +7445,7 @@ maybe we need one line more with some text\n")
(":w")
(file filename "line1\nline2\nline3\nline4\nline5\n"))))
(ert-info ("Write current buffer to new file")
- (let ((filename (evil-temp-filename)))
+ (let ((filename (make-temp-file "evil-test-write")))
(evil-test-buffer
"[l]ine1\nline2\nline3\nline4\nline5\n"
(delete-file filename)
@@ -7453,7 +7453,7 @@ maybe we need one line more with some text\n")
(file filename "line1\nline2\nline3\nline4\nline5\n")
(delete-file filename))))
(ert-info ("Write part of a buffer")
- (let ((filename (evil-temp-filename)))
+ (let ((filename (make-temp-file "evil-test-write")))
(evil-test-buffer
"[l]ine1\nline2\nline3\nline4\nline5\n"
(delete-file filename)
@@ -7461,7 +7461,7 @@ maybe we need one line more with some text\n")
(file filename "line2\nline3\n")
(delete-file filename))))
(ert-info ("Appending a file")
- (let ((filename (evil-temp-filename)))
+ (let ((filename (make-temp-file "evil-test-write")))
(evil-test-buffer
"[l]ine1\nline2\nline3\nline4\nline5\n"
(delete-file filename)