aboutsummaryrefslogtreecommitdiffstats
path: root/test/lisp/files-tests.el
diff options
context:
space:
mode:
Diffstat (limited to 'test/lisp/files-tests.el')
-rw-r--r--test/lisp/files-tests.el17
1 files changed, 17 insertions, 0 deletions
diff --git a/test/lisp/files-tests.el b/test/lisp/files-tests.el
index aadb60e1de7..8f6495a293c 100644
--- a/test/lisp/files-tests.el
+++ b/test/lisp/files-tests.el
@@ -662,6 +662,23 @@ unquoted file names."
662 (files-tests--with-temp-non-special-and-file-name-handler (tmpfile nospecial) 662 (files-tests--with-temp-non-special-and-file-name-handler (tmpfile nospecial)
663 (should (equal (expand-file-name nospecial) nospecial)))) 663 (should (equal (expand-file-name nospecial) nospecial))))
664 664
665(ert-deftest files-tests-file-name-non-special-expand-file-name-tilde ()
666 (let ((process-environment
667 (cons (format "HOME=%s" temporary-file-directory) process-environment))
668 abbreviated-home-dir)
669 (files-tests--with-temp-non-special (tmpfile nospecial)
670 (let (file-name-handler-alist)
671 (setq nospecial (file-name-quote (abbreviate-file-name tmpfile))))
672 (should (equal (expand-file-name nospecial)
673 (expand-file-name (file-name-unquote nospecial t)))))
674 (files-tests--with-temp-non-special-and-file-name-handler (tmpfile nospecial)
675 (let (file-name-handler-alist)
676 (setq nospecial (file-name-quote (abbreviate-file-name tmpfile))))
677 (should-not
678 (equal (expand-file-name nospecial)
679 ;; The file name handler deletes the ".special" extension.
680 (expand-file-name (file-name-unquote nospecial t)))))))
681
665(ert-deftest files-tests-file-name-non-special-file-accessible-directory-p () 682(ert-deftest files-tests-file-name-non-special-file-accessible-directory-p ()
666 (files-tests--with-temp-non-special (tmpdir nospecial-dir t) 683 (files-tests--with-temp-non-special (tmpdir nospecial-dir t)
667 (should (file-accessible-directory-p nospecial-dir))) 684 (should (file-accessible-directory-p nospecial-dir)))