diff options
author | F. Jason Park <jp@neverwas.me> | 2022-12-29 06:43:19 -0800 |
---|---|---|
committer | F. Jason Park <jp@neverwas.me> | 2023-04-08 14:23:51 -0700 |
commit | ba7fe88b782ad516b4cbb5e99fb108f57a9235e2 (patch) | |
tree | e007fa2ce5bb1f6a8be089cd3713735c6556d5e3 /test | |
parent | 3a012d1db24d613814296139c98324df1d7ef71f (diff) | |
download | emacs-ba7fe88b782ad516b4cbb5e99fb108f57a9235e2.tar.gz |
Optionally prompt for more ERC entry-point params
* doc/misc/erc.texi: Update statement about availability of `:user'
keyword param when entry points called interactively.
* lisp/erc/erc/compat.el: Don't require `url-parse' when compiling.
Add forward declaration for `url-type'.
* lisp/erc/erc.el: Don't require `url-parse' when compiling. Add
forward declarations for accessors of `url' struct from `url-parse'
library.
(erc-select-read-args): Allow optionally calling entry points with a
prefix arg to access params `user' and `:full-name'.
(erc-tls): Update doc string.
* test/lisp/erc/erc-tests.el (erc-select-read-args): Add test for
extra args. (Bug#60428.)
Diffstat (limited to 'test')
-rw-r--r-- | test/lisp/erc/erc-tests.el | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/test/lisp/erc/erc-tests.el b/test/lisp/erc/erc-tests.el index beb4b4cef76..795864a2cc2 100644 --- a/test/lisp/erc/erc-tests.el +++ b/test/lisp/erc/erc-tests.el @@ -1161,7 +1161,18 @@ (erc-select-read-args)) (list :server "[::1]" :port 6667 - :nick "nick"))))) + :nick "nick")))) + + (ert-info ("Extra args use URL nick by default") + (should (equal (ert-simulate-keys "nick:sesame@localhost:6667\r\r\r\r" + (let ((current-prefix-arg '(4))) + (erc-select-read-args))) + (list :server "localhost" + :port 6667 + :nick "nick" + :user "nick" + :password "sesame" + :full-name "nick"))))) (ert-deftest erc-tls () (let (calls env) |