[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
master edb0862f5e6: ; Fix test failure from 2f181d60323 (new 'pp' implem
From: |
Jim Porter |
Subject: |
master edb0862f5e6: ; Fix test failure from 2f181d60323 (new 'pp' implementation) |
Date: |
Sun, 18 Jun 2023 17:38:17 -0400 (EDT) |
branch: master
commit edb0862f5e69240de90c30b8914af51778f26d31
Author: Jim Porter <jporterbugs@gmail.com>
Commit: Jim Porter <jporterbugs@gmail.com>
; Fix test failure from 2f181d60323 (new 'pp' implementation)
* test/lisp/eshell/esh-util-tests.el
(esh-util-test/eshell-stringify/list): Be more flexible when checking
stringification of nested lists.
---
test/lisp/eshell/esh-util-tests.el | 10 ++++++++--
1 file changed, 8 insertions(+), 2 deletions(-)
diff --git a/test/lisp/eshell/esh-util-tests.el
b/test/lisp/eshell/esh-util-tests.el
index ed841e96c7e..52b42fe915c 100644
--- a/test/lisp/eshell/esh-util-tests.el
+++ b/test/lisp/eshell/esh-util-tests.el
@@ -46,9 +46,15 @@
(ert-deftest esh-util-test/eshell-stringify/list ()
"Test that `eshell-stringify' correctly stringifies lists."
+ ;; These tests depend on the particulars of how Emacs pretty-prints
+ ;; lists; changes to the pretty-printer could result in different
+ ;; whitespace. We don't care about that, except to ensure there's
+ ;; no leading/trailing whitespace.
(should (equal (eshell-stringify '(1 2 3)) "(1 2 3)"))
- (should (equal (eshell-stringify '((1 2) (3 . 4)))
- "((1 2)\n (3 . 4))")))
+ (should (equal (replace-regexp-in-string
+ (rx (+ (or space "\n"))) " "
+ (eshell-stringify '((1 2) (3 . 4))))
+ "((1 2) (3 . 4))")))
(ert-deftest esh-util-test/eshell-stringify/complex ()
"Test that `eshell-stringify' correctly stringifies complex objects."
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- master edb0862f5e6: ; Fix test failure from 2f181d60323 (new 'pp' implementation),
Jim Porter <=