Add a couple of minibuffer completion tests
Add tests for regressions that followed commit ff3f17ca3c
.
See discussion here:
https://lists.gnu.org/archive/html/emacs-devel/2024-05/msg00701.html
* test/lisp/minibuffer-tests.el (completion-cycle)
(minibuffer-next-completion): New tests.
This commit is contained in:
parent
39d2f40252
commit
a9af70849d
1 changed files with 13 additions and 0 deletions
|
@ -630,5 +630,18 @@
|
|||
(previous-line-completion 7)
|
||||
(should (equal "aa1" (get-text-property (point) 'completion--string))))))
|
||||
|
||||
(ert-deftest completion-cycle ()
|
||||
(completing-read-with-minibuffer-setup '("aaa" "bbb" "ccc")
|
||||
(let ((completion-cycle-threshold t))
|
||||
(execute-kbd-macro (kbd "TAB TAB TAB"))
|
||||
(should (equal (minibuffer-contents) "ccc")))))
|
||||
|
||||
(ert-deftest minibuffer-next-completion ()
|
||||
(let ((default-directory (ert-resource-directory)))
|
||||
(completing-read-with-minibuffer-setup #'read-file-name-internal
|
||||
(insert "d/")
|
||||
(execute-kbd-macro (kbd "M-<down> M-<down> M-<down>"))
|
||||
(should (equal "data/minibuffer-test-cttq$$tion" (minibuffer-contents))))))
|
||||
|
||||
(provide 'minibuffer-tests)
|
||||
;;; minibuffer-tests.el ends here
|
||||
|
|
Loading…
Add table
Reference in a new issue