浏览代码

Add test for cons style INITIAL-INPUT

Ryan C. Thompson 7 年之前
父节点
当前提交
9c3fd68662
共有 1 个文件被更改,包括 6 次插入0 次删除
  1. 6 0
      tests/test-ido-completing-read+.el

+ 6 - 0
tests/test-ido-completing-read+.el

@@ -215,6 +215,12 @@ also accept a quoted list for the sake of convenience."
          (ido-completing-read+ "Prompt: " '("blue" "yellow" "green") nil nil "gr"))
        :to-equal "green"))
 
+    (it "should properly handle a cons INITIAL-INPUT"
+      (expect
+       (with-simulated-input "ee RET"
+         (ido-completing-read+ "Prompt: " '("blue" "yellow" "green") nil nil (cons "gr" 2)))
+       :to-equal "green"))
+
     (it "should properly handle both INITIAL-INPUT and DEF at the same time"
       (expect
        (with-simulated-input "RET"