mirror of
git://git.sv.gnu.org/emacs.git
synced 2026-02-16 09:14:18 +00:00
Add an expensive test for defcustom types
* admin/cus-test.el (cus-test-opts): Return the tests. * test/lisp/custom-tests.el (check-for-wrong-custom-types): Test custom types (bug#30990).
This commit is contained in:
parent
79762ffa61
commit
664927b525
2 changed files with 13 additions and 3 deletions
|
|
@ -370,7 +370,9 @@ This function is suitable for batch mode. E.g., invoke
|
|||
|
||||
in the Emacs source directory.
|
||||
Normally only tests options belonging to files in loaddefs.el.
|
||||
If optional argument ALL is non-nil, test all files with defcustoms."
|
||||
If optional argument ALL is non-nil, test all files with defcustoms.
|
||||
|
||||
Returns a list of variables with suspicious types."
|
||||
(interactive)
|
||||
(and noninteractive
|
||||
command-line-args-left
|
||||
|
|
@ -382,9 +384,12 @@ If optional argument ALL is non-nil, test all files with defcustoms."
|
|||
(message "Running %s" 'cus-test-apropos)
|
||||
(cus-test-apropos "")
|
||||
(if (not cus-test-errors)
|
||||
(message "No problems found")
|
||||
(progn
|
||||
(message "No problems found")
|
||||
nil)
|
||||
(message "The following options might have problems:")
|
||||
(cus-test-message cus-test-errors)))
|
||||
(cus-test-message cus-test-errors)
|
||||
cus-test-errors))
|
||||
|
||||
(defun cus-test-deps ()
|
||||
"Run a verbose version of `custom-load-symbol' on all atoms.
|
||||
|
|
|
|||
|
|
@ -147,4 +147,9 @@
|
|||
(widget-apply field :value-to-internal origvalue)
|
||||
"bar"))))))
|
||||
|
||||
(ert-deftest check-for-wrong-custom-types ()
|
||||
:tags '(:expensive-test)
|
||||
(load (concat installation-directory "admin/cus-test.el"))
|
||||
(should (null (cus-test-opts t))))
|
||||
|
||||
;;; custom-tests.el ends here
|
||||
|
|
|
|||
Loading…
Reference in a new issue