Fix test comments and add version checks for search functions

Co-authored-by: Kinneyzhang <38454496+Kinneyzhang@users.noreply.github.com>
This commit is contained in:
copilot-swe-agent[bot] 2025-12-11 03:49:05 +00:00
parent c34ab46cf4
commit 3e7d2881a9

View File

@ -203,7 +203,7 @@
(should (assoc 'layer1 tp-layer-alist))
(should (assoc 'layer2 tp-layer-alist))
(should (assoc 'layer3 tp-layer-alist))
;; Note: tp-group-define stores layers in reverse order (last defined is first)
;; Check all layers are present in the group
(let ((layers (cdr (assoc 'my-group tp-layer-groups))))
(should (= (length layers) 3))
(should (memq 'layer1 layers))
@ -524,6 +524,8 @@
(insert "Hello World")
(tp-put 7 12 'face 'bold)
(goto-char 1)
;; text-property-search-forward may not exist in all Emacs versions
(skip-unless (fboundp 'text-property-search-forward))
(let ((match (tp-forward 'face)))
(should match)
(should (= (prop-match-beginning match) 7)))))