1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2026-04-27 08:43:40 -07:00

; Add semantic highlighting test with 'when-let*'

* test/lisp/progmodes/elisp-mode-resources/semantic-highlighting.el:
Add test form with 'when-let*'.
* test/lisp/progmodes/elisp-mode-tests.el (elisp-test-font-lock):
Trust temporary test buffer.
This commit is contained in:
Eshel Yaron 2025-10-07 23:57:35 +02:00
parent 94d314d756
commit d1d06099d6
No known key found for this signature in database
GPG key ID: EF3EE9CA35D78618
2 changed files with 15 additions and 4 deletions

View file

@ -111,3 +111,13 @@
;; ^ elisp-macro-call
(foo))))
;; ^ elisp-macro-call
(when-let* ((foo (symbol-at-point))
;; ^ (elisp-macro-call font-lock-keyword-face)
;; ^ elisp-binding-variable
((commandp foo)))
;; ^ elisp-function-reference
;; ^ elisp-bound-variable
foo)
;; ^ elisp-bound-variable

View file

@ -1149,10 +1149,11 @@ evaluation of BODY."
(should-error (scan-sexps (+ (point-min) 3) 1))))
(ert-deftest elisp-test-font-lock ()
(let ((elisp-fontify-semantically t))
(ert-font-lock-test-file
(ert-resource-file "semantic-highlighting.el")
'emacs-lisp-mode)))
(ert-font-lock-test-file (ert-resource-file "semantic-highlighting.el")
(lambda ()
(emacs-lisp-mode)
(setq-local trusted-content :all
elisp-fontify-semantically t))))
(provide 'elisp-mode-tests)
;;; elisp-mode-tests.el ends here