aboutsummaryrefslogtreecommitdiffstats
path: root/test/lisp
diff options
context:
space:
mode:
authorMichael Albinus2017-12-08 16:37:53 +0100
committerMichael Albinus2017-12-09 11:35:04 +0100
commitb067fa1f7d2b24b8fdb7f178924eb4e296559738 (patch)
tree2e08075c13be89268ff1e87db790d1f0da689995 /test/lisp
parent6c1a31e43c76ed5c08a4c5bbf2afe4ddc64e9a65 (diff)
downloademacs-b067fa1f7d2b24b8fdb7f178924eb4e296559738.tar.gz
emacs-b067fa1f7d2b24b8fdb7f178924eb4e296559738.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/lisp')
-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 0d1e7d18d9b..a9d6e74ce26 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
@@ -4642,6 +4646,10 @@ process sentinels. They shall not disturb each other."
4642 4646
4643(ert-deftest tramp-test42-delay-load () 4647(ert-deftest tramp-test42-delay-load ()
4644 "Check that Tramp is loaded lazily, only when needed." 4648 "Check that Tramp is loaded lazily, only when needed."
4649 ;; The autoloaded Tramp objects are different since Emacs 26.1. We
4650 ;; cannot test older Emacsen, therefore.
4651 (skip-unless (tramp--test-emacs26-p))
4652
4645 ;; Tramp is neither loaded at Emacs startup, nor when completing a 4653 ;; Tramp is neither loaded at Emacs startup, nor when completing a
4646 ;; non-Tramp file name like "/foo". Completing a Tramp-alike file 4654 ;; non-Tramp file name like "/foo". Completing a Tramp-alike file
4647 ;; name like "/foo:" autoloads Tramp, when `tramp-mode' is t. 4655 ;; name like "/foo:" autoloads Tramp, when `tramp-mode' is t.
@@ -4654,8 +4662,8 @@ process sentinels. They shall not disturb each other."
4654 (message \"Tramp loaded: %%s\" (featurep 'tramp)) \ 4662 (message \"Tramp loaded: %%s\" (featurep 'tramp)) \
4655 (file-name-all-completions \"/foo:\" \"/\") \ 4663 (file-name-all-completions \"/foo:\" \"/\") \
4656 (message \"Tramp loaded: %%s\" (featurep 'tramp)))")) 4664 (message \"Tramp loaded: %%s\" (featurep 'tramp)))"))
4657 ;; Tramp doesn't load when `tramp-mode' is nil since Emacs 26.1. 4665 ;; Tramp doesn't load when `tramp-mode' is nil.
4658 (dolist (tm (if (tramp--test-emacs26-p) '(t nil) '(nil))) 4666 (dolist (tm '(t nil))
4659 (should 4667 (should
4660 (string-match 4668 (string-match
4661 (format 4669 (format
@@ -4693,6 +4701,10 @@ process sentinels. They shall not disturb each other."
4693 4701
4694(ert-deftest tramp-test42-remote-load-path () 4702(ert-deftest tramp-test42-remote-load-path ()
4695 "Check that Tramp autoloads its packages with remote `load-path'." 4703 "Check that Tramp autoloads its packages with remote `load-path'."
4704 ;; The autoloaded Tramp objects are different since Emacs 26.1. We
4705 ;; cannot test older Emacsen, therefore.
4706 (skip-unless (tramp--test-emacs26-p))
4707
4696 ;; `tramp-cleanup-all-connections' is autoloaded from tramp-cmds.el. 4708 ;; `tramp-cleanup-all-connections' is autoloaded from tramp-cmds.el.
4697 ;; It shall still work, when a remote file name is in the 4709 ;; It shall still work, when a remote file name is in the
4698 ;; `load-path'. 4710 ;; `load-path'.
@@ -4770,6 +4782,8 @@ Since it unloads Tramp, it shall be the last test to run."
4770 4782
4771;; * dired-compress-file 4783;; * dired-compress-file
4772;; * dired-uncache 4784;; * dired-uncache
4785;; * file-equal-p (partly done in `tramp-test21-file-links')
4786;; * file-in-directory-p
4773;; * file-name-case-insensitive-p 4787;; * file-name-case-insensitive-p
4774 4788
4775;; * Work on skipped tests. Make a comment, when it is impossible. 4789;; * Work on skipped tests. Make a comment, when it is impossible.