aboutsummaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
authorMichael Albinus2017-12-08 16:37:53 +0100
committerMichael Albinus2017-12-08 16:37:53 +0100
commit7eea3144d4863325ff249b1fde290c3280da4a61 (patch)
tree7aa4fa9a49f89f9f54d003fc447d6f0ce2f88b8e /test
parentc0a670a8b5833b81ef82c3f08ba9ddd68412ebe0 (diff)
downloademacs-7eea3144d4863325ff249b1fde290c3280da4a61.tar.gz
emacs-7eea3144d4863325ff249b1fde290c3280da4a61.zip
Minor Tramp fixes
* lisp/net/tramp-gvfs.el (tramp-gvfs-do-copy-or-rename-file): Fix a bug when renaming. * test/lisp/net/tramp-tests.el (tramp-test21-file-links): Extend test. (tramp-test42-delay-load, tramp-test42-remote-load-path): Skip unless Emacs >= 26.
Diffstat (limited to 'test')
-rw-r--r--test/lisp/net/tramp-tests.el20
1 files changed, 17 insertions, 3 deletions
diff --git a/test/lisp/net/tramp-tests.el b/test/lisp/net/tramp-tests.el
index 0490daa9575..1261a81378d 100644
--- a/test/lisp/net/tramp-tests.el
+++ b/test/lisp/net/tramp-tests.el
@@ -2810,7 +2810,11 @@ This tests also `make-symbolic-link', `file-truename' and `add-name-to-file'."
2810 ;; Symbolic links could look like a remote file name. 2810 ;; Symbolic links could look like a remote file name.
2811 ;; They must be quoted then. 2811 ;; They must be quoted then.
2812 (delete-file tmp-name2) 2812 (delete-file tmp-name2)
2813 (make-symbolic-link "/penguin:motd:" tmp-name2) 2813 (make-symbolic-link
2814 (funcall
2815 (if quoted 'tramp-compat-file-name-unquote 'identity)
2816 "/penguin:motd:")
2817 tmp-name2)
2814 (should (file-symlink-p tmp-name2)) 2818 (should (file-symlink-p tmp-name2))
2815 (should 2819 (should
2816 (string-equal 2820 (string-equal
@@ -4631,6 +4635,10 @@ process sentinels. They shall not disturb each other."
4631 4635
4632(ert-deftest tramp-test42-delay-load () 4636(ert-deftest tramp-test42-delay-load ()
4633 "Check that Tramp is loaded lazily, only when needed." 4637 "Check that Tramp is loaded lazily, only when needed."
4638 ;; The autoloaded Tramp objects are different since Emacs 26.1. We
4639 ;; cannot test older Emacsen, therefore.
4640 (skip-unless (tramp--test-emacs26-p))
4641
4634 ;; Tramp is neither loaded at Emacs startup, nor when completing a 4642 ;; Tramp is neither loaded at Emacs startup, nor when completing a
4635 ;; non-Tramp file name like "/foo". Completing a Tramp-alike file 4643 ;; non-Tramp file name like "/foo". Completing a Tramp-alike file
4636 ;; name like "/foo:" autoloads Tramp, when `tramp-mode' is t. 4644 ;; name like "/foo:" autoloads Tramp, when `tramp-mode' is t.
@@ -4643,8 +4651,8 @@ process sentinels. They shall not disturb each other."
4643 (message \"Tramp loaded: %%s\" (featurep 'tramp)) \ 4651 (message \"Tramp loaded: %%s\" (featurep 'tramp)) \
4644 (file-name-all-completions \"/foo:\" \"/\") \ 4652 (file-name-all-completions \"/foo:\" \"/\") \
4645 (message \"Tramp loaded: %%s\" (featurep 'tramp)))")) 4653 (message \"Tramp loaded: %%s\" (featurep 'tramp)))"))
4646 ;; Tramp doesn't load when `tramp-mode' is nil since Emacs 26.1. 4654 ;; Tramp doesn't load when `tramp-mode' is nil.
4647 (dolist (tm (if (tramp--test-emacs26-p) '(t nil) '(nil))) 4655 (dolist (tm '(t nil))
4648 (should 4656 (should
4649 (string-match 4657 (string-match
4650 (format 4658 (format
@@ -4682,6 +4690,10 @@ process sentinels. They shall not disturb each other."
4682 4690
4683(ert-deftest tramp-test42-remote-load-path () 4691(ert-deftest tramp-test42-remote-load-path ()
4684 "Check that Tramp autoloads its packages with remote `load-path'." 4692 "Check that Tramp autoloads its packages with remote `load-path'."
4693 ;; The autoloaded Tramp objects are different since Emacs 26.1. We
4694 ;; cannot test older Emacsen, therefore.
4695 (skip-unless (tramp--test-emacs26-p))
4696
4685 ;; `tramp-cleanup-all-connections' is autoloaded from tramp-cmds.el. 4697 ;; `tramp-cleanup-all-connections' is autoloaded from tramp-cmds.el.
4686 ;; It shall still work, when a remote file name is in the 4698 ;; It shall still work, when a remote file name is in the
4687 ;; `load-path'. 4699 ;; `load-path'.
@@ -4759,6 +4771,8 @@ Since it unloads Tramp, it shall be the last test to run."
4759 4771
4760;; * dired-compress-file 4772;; * dired-compress-file
4761;; * dired-uncache 4773;; * dired-uncache
4774;; * file-equal-p (partly done in `tramp-test21-file-links')
4775;; * file-in-directory-p
4762;; * file-name-case-insensitive-p 4776;; * file-name-case-insensitive-p
4763 4777
4764;; * Work on skipped tests. Make a comment, when it is impossible. 4778;; * Work on skipped tests. Make a comment, when it is impossible.