summaryrefslogtreecommitdiff
path: root/test/lisp/emacs-lisp/pp-tests.el
diff options
context:
space:
mode:
authorLars Ingebrigtsen <larsi@gnus.org>2021-11-04 21:44:46 +0100
committerLars Ingebrigtsen <larsi@gnus.org>2021-11-04 21:44:53 +0100
commit6cf86ed4c1c7b5a7b74630347de0dfb413d3cd18 (patch)
treeeb86a0a4bd114db63d9e41880386f0a8d0e6e91d /test/lisp/emacs-lisp/pp-tests.el
parent4c6afb527bddf9e9f481dd6f6627ffd5407b8803 (diff)
downloademacs-6cf86ed4c1c7b5a7b74630347de0dfb413d3cd18.tar.gz
Add new basic Emacs Lisp code formatting function
* lisp/emacs-lisp/pp.el (pp-emacs-lisp-code): New interface function. (pp): Mention it. (pp--insert-lisp, pp--format-vector, pp--format-list) (pp--format-function, pp--format-definition, pp--insert-binding) (pp--insert, pp--indent-buffer): New helper functions.
Diffstat (limited to 'test/lisp/emacs-lisp/pp-tests.el')
-rw-r--r--test/lisp/emacs-lisp/pp-tests.el4
1 files changed, 4 insertions, 0 deletions
diff --git a/test/lisp/emacs-lisp/pp-tests.el b/test/lisp/emacs-lisp/pp-tests.el
index b04030cc432..4cae1a73775 100644
--- a/test/lisp/emacs-lisp/pp-tests.el
+++ b/test/lisp/emacs-lisp/pp-tests.el
@@ -20,6 +20,7 @@
;;; Code:
(require 'pp)
+(require 'ert-x)
(ert-deftest pp-print-quote ()
(should (string= (pp-to-string 'quote) "quote"))
@@ -32,4 +33,7 @@
(should (string= (pp-to-string '(quotefoo)) "(quotefoo)\n"))
(should (string= (pp-to-string '(a b)) "(a b)\n")))
+(ert-deftest test-indentation ()
+ (ert-test-erts-file (ert-resource-file "code-formats.erts")))
+
;;; pp-tests.el ends here.