diff options
author | Sean Whitton <spwhitton@spwhitton.name> | 2021-01-31 22:34:48 -0700 |
---|---|---|
committer | Sean Whitton <spwhitton@spwhitton.name> | 2021-01-31 22:34:48 -0700 |
commit | d4d613629b59d2eadd80026cab6c9dabc92cab24 (patch) | |
tree | d31086a817251dddb847d027661d218c1ecd6540 /test/lisp/minibuffer-tests.el | |
parent | fdb813e529602914360fc2d0cf22e42e32e6905f (diff) | |
parent | a5438ee11ad052e71334dcfb2db51fb9123411e5 (diff) | |
download | emacs-d4d613629b59d2eadd80026cab6c9dabc92cab24.tar.gz |
Merge remote-tracking branch 'origin/master' into athena/unstable
Diffstat (limited to 'test/lisp/minibuffer-tests.el')
-rw-r--r-- | test/lisp/minibuffer-tests.el | 24 |
1 files changed, 21 insertions, 3 deletions
diff --git a/test/lisp/minibuffer-tests.el b/test/lisp/minibuffer-tests.el index 3ebca14a284..7349b191caf 100644 --- a/test/lisp/minibuffer-tests.el +++ b/test/lisp/minibuffer-tests.el @@ -1,4 +1,4 @@ -;;; completion-tests.el --- Tests for completion functions -*- lexical-binding: t; -*- +;;; minibuffer-tests.el --- Tests for completion functions -*- lexical-binding: t; -*- ;; Copyright (C) 2013-2021 Free Software Foundation, Inc. @@ -107,5 +107,23 @@ nil (length input)) (cons output (length output))))))) -(provide 'completion-tests) -;;; completion-tests.el ends here +(ert-deftest completion--insert-strings-faces () + (with-temp-buffer + (completion--insert-strings + '(("completion1" "suffix1"))) + (should (equal (get-text-property 12 'face) '(completions-annotations)))) + (with-temp-buffer + (completion--insert-strings + '(("completion1" #("suffix1" 0 7 (face shadow))))) + (should (equal (get-text-property 12 'face) 'shadow))) + (with-temp-buffer + (completion--insert-strings + '(("completion1" "prefix1" "suffix1"))) + (should (equal (get-text-property 19 'face) nil))) + (with-temp-buffer + (completion--insert-strings + '(("completion1" "prefix1" #("suffix1" 0 7 (face shadow))))) + (should (equal (get-text-property 19 'face) 'shadow)))) + +(provide 'minibuffer-tests) +;;; minibuffer-tests.el ends here |