diff options
author | Po Lu <luangruo@yahoo.com> | 2022-06-21 10:12:00 +0800 |
---|---|---|
committer | Po Lu <luangruo@yahoo.com> | 2022-06-21 10:12:00 +0800 |
commit | 1d681a57005c837a58c9b3a365bc59f7293c4df5 (patch) | |
tree | 936d15c7d984b39f23c9b3c0ceeb06df66d3427a /test/lisp/dnd-tests.el | |
parent | 01834ba0c9c1ed5d6b25a1463b79b00e2fc7266b (diff) | |
download | emacs-1d681a57005c837a58c9b3a365bc59f7293c4df5.tar.gz emacs-1d681a57005c837a58c9b3a365bc59f7293c4df5.tar.bz2 emacs-1d681a57005c837a58c9b3a365bc59f7293c4df5.zip |
Add test for bug#56078 fix
* test/lisp/dnd-tests.el (dnd-tests-open-remote-url): New test.
Diffstat (limited to 'test/lisp/dnd-tests.el')
-rw-r--r-- | test/lisp/dnd-tests.el | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/test/lisp/dnd-tests.el b/test/lisp/dnd-tests.el index dfd441b56df..3ee92286f96 100644 --- a/test/lisp/dnd-tests.el +++ b/test/lisp/dnd-tests.el @@ -371,5 +371,18 @@ This function only tries to handle strings." (should-not (dnd-get-local-file-uri "file://some-remote-host/path/to/foo")) (should-not (dnd-get-local-file-uri "file:///path/to/foo"))) +(ert-deftest dnd-tests-open-remote-url () + ;; Expensive test to make sure opening an FTP URL during + ;; drag-and-drop works. + :tags '(:expensive-test) + ;; Don't run this test if the FTP server isn't reachable. + (skip-unless (and (fboundp 'network-lookup-address-info) + (network-lookup-address-info "ftp.gnu.org"))) + ;; Make sure bug#56078 doesn't happen again. + (let ((url "ftp://anonymous@ftp.gnu.org/") + ;; This prints a bunch of annoying spaces to stdout. + (inhibit-message t)) + (should (prog1 t (dnd-open-remote-url url 'private))))) + (provide 'dnd-tests) ;;; dnd-tests.el ends here |