aboutsummaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
authorMichael Albinus2021-05-07 17:25:49 +0200
committerMichael Albinus2021-05-07 17:25:49 +0200
commit9457d4f20f1f3da8450924cfe1f776fdd04261bb (patch)
treec7a4363c8722e523bfe3f1dabb57962aec4d0acc /test
parent615cf550f22f78d123acb1e8e90be6c69699dbee (diff)
downloademacs-9457d4f20f1f3da8450924cfe1f776fdd04261bb.tar.gz
emacs-9457d4f20f1f3da8450924cfe1f776fdd04261bb.zip
Tramp: Fix file name quoting on MS Windows
* lisp/net/tramp-sh.el (tramp-make-copy-program-file-name): Use `tramp-unquote-shell-quote-argument'. * lisp/net/tramp.el (tramp-unquote-shell-quote-argument): Adapt for MS Windows. * test/lisp/net/tramp-tests.el (tramp--test-special-characters): Adapt for MS Windows.
Diffstat (limited to 'test')
-rw-r--r--test/lisp/net/tramp-tests.el15
1 files changed, 7 insertions, 8 deletions
diff --git a/test/lisp/net/tramp-tests.el b/test/lisp/net/tramp-tests.el
index 0f6f3b79800..03915d7a3fc 100644
--- a/test/lisp/net/tramp-tests.el
+++ b/test/lisp/net/tramp-tests.el
@@ -5882,6 +5882,7 @@ This requires restrictions of file name syntax."
5882 (make-directory tmp-name2) 5882 (make-directory tmp-name2)
5883 5883
5884 (dolist (elt files) 5884 (dolist (elt files)
5885 ;(tramp--test-message "%s" elt)
5885 (let* ((file1 (expand-file-name elt tmp-name1)) 5886 (let* ((file1 (expand-file-name elt tmp-name1))
5886 (file2 (expand-file-name elt tmp-name2)) 5887 (file2 (expand-file-name elt tmp-name2))
5887 (file3 (expand-file-name (concat elt "foo") tmp-name1))) 5888 (file3 (expand-file-name (concat elt "foo") tmp-name1)))
@@ -6071,7 +6072,8 @@ This requires restrictions of file name syntax."
6071 "\tfoo bar baz\t") 6072 "\tfoo bar baz\t")
6072 (t " foo\tbar baz\t")) 6073 (t " foo\tbar baz\t"))
6073 "@foo@bar@baz@" 6074 "@foo@bar@baz@"
6074 "$foo$bar$$baz$" 6075 (unless (tramp--test-windows-nt-and-scp-p)
6076 "$foo$bar$$baz$")
6075 "-foo-bar-baz-" 6077 "-foo-bar-baz-"
6076 "%foo%bar%baz%" 6078 "%foo%bar%baz%"
6077 "&foo&bar&baz&" 6079 "&foo&bar&baz&"
@@ -6087,9 +6089,10 @@ This requires restrictions of file name syntax."
6087 "'foo'bar'baz'" 6089 "'foo'bar'baz'"
6088 "'foo\"bar'baz\"") 6090 "'foo\"bar'baz\"")
6089 "#foo~bar#baz~" 6091 "#foo~bar#baz~"
6090 (if (or (tramp--test-gvfs-p) (tramp--test-windows-nt-or-smb-p)) 6092 (unless (tramp--test-windows-nt-and-scp-p)
6091 "!foo!bar!baz!" 6093 (if (or (tramp--test-gvfs-p) (tramp--test-windows-nt-or-smb-p))
6092 "!foo|bar!baz|") 6094 "!foo!bar!baz!"
6095 "!foo|bar!baz|"))
6093 (if (or (tramp--test-gvfs-p) 6096 (if (or (tramp--test-gvfs-p)
6094 (tramp--test-rclone-p) 6097 (tramp--test-rclone-p)
6095 (tramp--test-windows-nt-or-smb-p)) 6098 (tramp--test-windows-nt-or-smb-p))
@@ -6110,7 +6113,6 @@ This requires restrictions of file name syntax."
6110 "Check special characters in file names." 6113 "Check special characters in file names."
6111 (skip-unless (tramp--test-enabled)) 6114 (skip-unless (tramp--test-enabled))
6112 (skip-unless (not (tramp--test-rsync-p))) 6115 (skip-unless (not (tramp--test-rsync-p)))
6113; (skip-unless (not (tramp--test-windows-nt-and-scp-p)))
6114 (skip-unless (or (tramp--test-emacs26-p) (not (tramp--test-rclone-p)))) 6116 (skip-unless (or (tramp--test-emacs26-p) (not (tramp--test-rclone-p))))
6115 6117
6116 (tramp--test-special-characters)) 6118 (tramp--test-special-characters))
@@ -6122,7 +6124,6 @@ Use the `stat' command."
6122 (skip-unless (tramp--test-enabled)) 6124 (skip-unless (tramp--test-enabled))
6123 (skip-unless (tramp--test-sh-p)) 6125 (skip-unless (tramp--test-sh-p))
6124 (skip-unless (not (tramp--test-rsync-p))) 6126 (skip-unless (not (tramp--test-rsync-p)))
6125; (skip-unless (not (tramp--test-windows-nt-and-scp-p)))
6126 ;; We cannot use `tramp-test-vec', because this fails during compilation. 6127 ;; We cannot use `tramp-test-vec', because this fails during compilation.
6127 (with-parsed-tramp-file-name tramp-test-temporary-file-directory nil 6128 (with-parsed-tramp-file-name tramp-test-temporary-file-directory nil
6128 (skip-unless (tramp-get-remote-stat v))) 6129 (skip-unless (tramp-get-remote-stat v)))
@@ -6141,7 +6142,6 @@ Use the `perl' command."
6141 (skip-unless (tramp--test-enabled)) 6142 (skip-unless (tramp--test-enabled))
6142 (skip-unless (tramp--test-sh-p)) 6143 (skip-unless (tramp--test-sh-p))
6143 (skip-unless (not (tramp--test-rsync-p))) 6144 (skip-unless (not (tramp--test-rsync-p)))
6144; (skip-unless (not (tramp--test-windows-nt-and-scp-p)))
6145 ;; We cannot use `tramp-test-vec', because this fails during compilation. 6145 ;; We cannot use `tramp-test-vec', because this fails during compilation.
6146 (with-parsed-tramp-file-name tramp-test-temporary-file-directory nil 6146 (with-parsed-tramp-file-name tramp-test-temporary-file-directory nil
6147 (skip-unless (tramp-get-remote-perl v))) 6147 (skip-unless (tramp-get-remote-perl v)))
@@ -6163,7 +6163,6 @@ Use the `ls' command."
6163 (skip-unless (tramp--test-enabled)) 6163 (skip-unless (tramp--test-enabled))
6164 (skip-unless (tramp--test-sh-p)) 6164 (skip-unless (tramp--test-sh-p))
6165 (skip-unless (not (tramp--test-rsync-p))) 6165 (skip-unless (not (tramp--test-rsync-p)))
6166; (skip-unless (not (tramp--test-windows-nt-and-scp-p)))
6167 6166
6168 (let ((tramp-connection-properties 6167 (let ((tramp-connection-properties
6169 (append 6168 (append