diff options
author | Mattias EngdegÄrd <mattiase@acm.org> | 2020-10-27 13:20:20 +0100 |
---|---|---|
committer | Mattias EngdegÄrd <mattiase@acm.org> | 2020-10-27 13:20:20 +0100 |
commit | 88f5530a9b861ae3f3003171ef9efa98ab1f8222 (patch) | |
tree | a33dd7db2aee7253d94ffeb841527df9f2b709b2 /lisp/emacs-lisp | |
parent | cde72637dfd6989081ed8b2f26e7187c309780b8 (diff) | |
download | emacs-88f5530a9b861ae3f3003171ef9efa98ab1f8222.tar.gz emacs-88f5530a9b861ae3f3003171ef9efa98ab1f8222.tar.bz2 emacs-88f5530a9b861ae3f3003171ef9efa98ab1f8222.zip |
ERT: escape control characters in pretty-printed error output
* lisp/emacs-lisp/ert.el (ert--pp-with-indentation-and-newline):
Escape control characters which would otherwise be blasted directly to
the terminal (when running noninteractively) with unpleasant results.
Diffstat (limited to 'lisp/emacs-lisp')
-rw-r--r-- | lisp/emacs-lisp/ert.el | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lisp/emacs-lisp/ert.el b/lisp/emacs-lisp/ert.el index ebb27e8a62c..baa04f2c6af 100644 --- a/lisp/emacs-lisp/ert.el +++ b/lisp/emacs-lisp/ert.el @@ -1305,7 +1305,8 @@ EXPECTEDP specifies whether the result was expected." "Pretty-print OBJECT, indenting it to the current column of point. Ensures a final newline is inserted." (let ((begin (point)) - (pp-escape-newlines nil)) + (pp-escape-newlines nil) + (print-escape-control-characters t)) (pp object (current-buffer)) (unless (bolp) (insert "\n")) (save-excursion |