From: Lars Ingebrigtsen Date: Thu, 21 Oct 2021 04:24:35 +0000 (+0200) Subject: Fix hi-lock AOT test failures (bug#51308) X-Git-Tag: emacs-28.0.90~229 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=8f42ff31f6;p=emacs.git Fix hi-lock AOT test failures (bug#51308) --- diff --git a/test/lisp/hi-lock-tests.el b/test/lisp/hi-lock-tests.el index 199512fe7de..200caa7e1ad 100644 --- a/test/lisp/hi-lock-tests.el +++ b/test/lisp/hi-lock-tests.el @@ -31,7 +31,8 @@ (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))) @@ -43,7 +44,8 @@ (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))) @@ -89,7 +91,8 @@ (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)) @@ -142,7 +145,8 @@ (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)) @@ -155,7 +159,8 @@ (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")