From: Yuan Fu Date: Fri, 12 Mar 2021 17:18:22 +0000 (-0500) Subject: Fix simple-tests--undo* X-Git-Tag: emacs-28.0.90~3292 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=75705b302dd025dc2d678124aa1b7bd52a8d35b2;p=emacs.git Fix simple-tests--undo* * test/lisp/simple-tests.el (simple-tests--undo-in-region, simple-tests--undo-equiv-table): Re-enable in batch mode. Enable 'transient-mark-mode' in temp buffer. --- diff --git a/test/lisp/simple-tests.el b/test/lisp/simple-tests.el index 8fa8295765b..601eca6cd49 100644 --- a/test/lisp/simple-tests.el +++ b/test/lisp/simple-tests.el @@ -469,8 +469,11 @@ See bug#35036." (ert-deftest simple-tests--undo-in-region () ;; Test undo/redo in region. - (skip-unless (not noninteractive)) (with-temp-buffer + ;; Enable `transient-mark-mode' so `region-active-p' works as + ;; expected. `region-active-p' is used to determine whether to + ;; perform regional undo in `undo'. + (transient-mark-mode) (buffer-enable-undo) (dolist (x '("a" "b" "c" "d" "e")) (insert x) @@ -506,9 +509,9 @@ See bug#35036." lst) (ert-deftest simple-tests--undo-equiv-table () - (skip-unless (not noninteractive)) (with-temp-buffer (buffer-enable-undo) + (transient-mark-mode) (let ((ul-hash-table (make-hash-table :test #'equal))) (dolist (x '("a" "b" "c")) (insert x)