branch: externals/hyperbole commit e85b09bef4bad29c3b9bad3bad1d5604c360791b Author: Mats Lidell <mats.lid...@lidells.se> Commit: GitHub <nore...@github.com>
Use messages-buffer, run test case only interactively (#205) --- ChangeLog | 8 ++++++++ test/hui-select-tests.el | 3 ++- test/hy-test-helpers.el | 4 ++-- 3 files changed, 12 insertions(+), 3 deletions(-) diff --git a/ChangeLog b/ChangeLog index 19b7a3cc4c..60ae35aa04 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,11 @@ +2022-07-11 Mats Lidell <ma...@gnu.org> + +* test/hy-test-helpers.el (hy-test-helpers:should-last-message): Use + function messages-buffer for getting the *Messages* buffer. + +* test/hui-select-tests.el (hui-select--thing): Limit test case to run in + interactive mode, i.e. make test-all. + 2022-06-19 Bob Weiner <r...@gnu.org> * test/demo-tests.el (fast-demo-key-series-shell-apropos): Allow optional space diff --git a/test/hui-select-tests.el b/test/hui-select-tests.el index c8e76cfc8f..93d30636e7 100644 --- a/test/hui-select-tests.el +++ b/test/hui-select-tests.el @@ -3,7 +3,7 @@ ;; Author: Mats Lidell <ma...@gnu.org> ;; ;; Orig-Date: 14-Apr-22 at 23:45:52 -;; Last-Mod: 15-Apr-22 at 23:53:52 by Mats Lidell +;; Last-Mod: 11-Jul-22 at 23:29:45 by Mats Lidell ;; ;; Copyright (C) 2021 Free Software Foundation, Inc. ;; See the "../HY-COPY" file for license information. @@ -80,6 +80,7 @@ (ert-deftest hui-select--thing () "`hui-select-thing' selects bigger sections of text when called repeatedly." + (skip-unless (not noninteractive)) (hui-select-reset) (with-temp-buffer (insert "Buffer\n\nParagraph\nline. One word.\n") diff --git a/test/hy-test-helpers.el b/test/hy-test-helpers.el index 952b425cad..18c6d84bd5 100644 --- a/test/hy-test-helpers.el +++ b/test/hy-test-helpers.el @@ -3,7 +3,7 @@ ;; Author: Mats Lidell <ma...@gnu.org> ;; ;; Orig-Date: 30-Jan-21 at 12:00:00 -;; Last-Mod: 24-Jan-22 at 00:40:54 by Bob Weiner +;; Last-Mod: 11-Jul-22 at 23:23:08 by Mats Lidell ;; ;; Copyright (C) 2021-2022 Free Software Foundation, Inc. ;; See the "HY-COPY" file for license information. @@ -27,7 +27,7 @@ (defun hy-test-helpers:should-last-message (msg) "Verify last message is MSG." - (with-current-buffer "*Messages*" + (with-current-buffer (messages-buffer) (should (save-excursion (goto-char (point-max)) (search-backward msg (- (point-max) 350))))))