(with-temp-buffer
(insert "a A b B\n")
(cl-letf (((symbol-function 'completing-read)
- (lambda (_prompt _coll _x _y _z _hist defaults)
+ (lambda (_prompt _coll
+ &optional _x _y _z _hist defaults _inherit)
(car defaults))))
(dotimes (_ 2)
(let ((face (hi-lock-read-face-name)))
(with-temp-buffer
(insert "foo bar")
(cl-letf (((symbol-function 'completing-read)
- (lambda (_prompt _coll _x _y _z _hist defaults)
+ (lambda (_prompt _coll
+ &optional _x _y _z _hist defaults _inherit)
(car defaults))))
(hi-lock-set-pattern "9999" (hi-lock-read-face-name)) ; No match
(hi-lock-set-pattern "foo" (hi-lock-read-face-name)))
(let ((search-spaces-regexp search-whitespace-regexp)) (highlight-regexp "a a"))
(should (= (length (overlays-in (point-min) (point-max))) 1))
(cl-letf (((symbol-function 'completing-read)
- (lambda (_prompt _coll _x _y _z _hist defaults)
+ (lambda (_prompt _coll
+ &optional _x _y _z _hist defaults _inherit)
(car defaults))))
(call-interactively 'unhighlight-regexp))
(should (= (length (overlays-in (point-min) (point-max))) 0))
(font-lock-ensure)
(should (memq 'hi-yellow (get-text-property 1 'face)))
(cl-letf (((symbol-function 'completing-read)
- (lambda (_prompt _coll _x _y _z _hist defaults)
+ (lambda (_prompt _coll
+ &optional _x _y _z _hist defaults _inherit)
(car defaults)))
(font-lock-fontified t))
(call-interactively 'unhighlight-regexp))
(insert "aAbB\n")
(cl-letf (((symbol-function 'completing-read)
- (lambda (_prompt _coll _x _y _z _hist defaults)
+ (lambda (_prompt _coll
+ &optional _x _y _z _hist defaults _inherit)
(car defaults))))
(highlight-regexp "a")