Repair setopt test after error demotion to warning
* test/lisp/cus-edit-tests.el (test-setopt): Check for a warrning instead of an error in attempt to call `setopt` with a value that does not match the declared type (bug#60162).
This commit is contained in:
parent
12e26cc0c1
commit
b3e7768a0e
1 changed files with 9 additions and 2 deletions
|
@ -83,7 +83,14 @@
|
|||
(ert-deftest test-setopt ()
|
||||
(should (= (setopt cus-edit-test-foo1 1) 1))
|
||||
(should (= cus-edit-test-foo1 1))
|
||||
(should-error (setopt cus-edit-test-foo1 :foo)))
|
||||
|
||||
(let* ((text-quoting-style 'grave)
|
||||
(warn-txt
|
||||
(with-current-buffer (get-buffer-create "*Warnings*")
|
||||
(let ((inhibit-read-only t))
|
||||
(erase-buffer))
|
||||
(setopt cus-edit-test-foo1 :foo)
|
||||
(buffer-substring-no-properties (point-min) (point-max)))))
|
||||
(should (string-search "Value `:foo' does not match type number"
|
||||
warn-txt))))
|
||||
(provide 'cus-edit-tests)
|
||||
;;; cus-edit-tests.el ends here
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue