summaryrefslogtreecommitdiff
path: root/test/lisp/files-tests.el
diff options
context:
space:
mode:
authorPaul Eggert <eggert@cs.ucla.edu>2022-12-17 12:15:30 -0800
committerPaul Eggert <eggert@cs.ucla.edu>2022-12-17 14:24:16 -0800
commit8a9579ca29df951ace35125873949e905fd1af2b (patch)
treec0742b4d88da2c78a24dc4be844c9ec436d96520 /test/lisp/files-tests.el
parent627e7e0243d6df73b7cc93fb7a106a61c944b3bf (diff)
downloademacs-8a9579ca29df951ace35125873949e905fd1af2b.tar.gz
Use make-directory handlers uniformly
Formerly, the code supported both make-directory and make-directory-internal handlers. This led to confusion and meant than in a few cases (nnmaildir, ido) remote directories could not be used in some cases. Fix this by using only make-directory handlers. Perhaps there used to be a reason for why there were both make-directory and make-directory-internal handlers, but whatever that reason was, it seems to have vanished even before now. There is no longer any need for make-directory-internal handlers, as the few remaining callers that use make-directory-internal do so only when there are no handlers. However, this change keeps the existing make-directory-internal handlers for now, in case this code is ever used in older Emacs versions that still call those handlers. * lisp/gnus/nnmaildir.el (nnmaildir--mkdir): * lisp/ido.el (ido-file-internal): * lisp/net/tramp-smb.el (tramp-smb-handle-make-directory): Use make-directory, not make-directory-internal. * lisp/net/tramp-smb.el (tramp-smb-handle-make-directory-internal): Now obsolete. * src/fileio.c (Fmake_directory_internal): Do not look for or use a make-directory-internal handler. * test/lisp/files-tests.el: (files-tests-file-name-non-special-make-directory-internal): Remove, as this test incorrectly assumes that make-directory-internal must support handlers.
Diffstat (limited to 'test/lisp/files-tests.el')
-rw-r--r--test/lisp/files-tests.el11
1 files changed, 0 insertions, 11 deletions
diff --git a/test/lisp/files-tests.el b/test/lisp/files-tests.el
index 682b5cdb449..efafb5583ac 100644
--- a/test/lisp/files-tests.el
+++ b/test/lisp/files-tests.el
@@ -1038,17 +1038,6 @@ unquoted file names."
(let ((default-directory nospecial-dir))
(should-error (make-directory "dir")))))
-(ert-deftest files-tests-file-name-non-special-make-directory-internal ()
- (files-tests--with-temp-non-special (tmpdir nospecial-dir t)
- (let ((default-directory nospecial-dir))
- (make-directory-internal "dir")
- (should (file-directory-p "dir"))
- (delete-directory "dir")))
- (files-tests--with-temp-non-special-and-file-name-handler
- (tmpdir nospecial-dir t)
- (let ((default-directory nospecial-dir))
- (should-error (make-directory-internal "dir")))))
-
(ert-deftest files-tests-file-name-non-special-make-nearby-temp-file ()
(let* ((default-directory (file-name-quote temporary-file-directory))
(near-tmpfile (make-nearby-temp-file "file")))