aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorStefan Monnier2025-04-18 09:35:14 -0400
committerStefan Monnier2025-04-18 09:35:14 -0400
commitf5e6f284e9f970cdbdfb25c8ae8308165f3ce5c5 (patch)
tree7a6139a0a3b0af9ef7d41a8ebe0690f45b3b1ae7
parent9f0c43a3d1b38c93bf21bf25db0f5dd489338d7c (diff)
downloademacs-f5e6f284e9f970cdbdfb25c8ae8308165f3ce5c5.tar.gz
emacs-f5e6f284e9f970cdbdfb25c8ae8308165f3ce5c5.zip
(tab-bar-tests-quit-restore-window): Try and clarify the skip
* test/lisp/tab-bar-tests.el (tab-bar-tests-quit-restore-window): Rewrite the `skip-unless` based on the code's history because I found the current code quite confusing.
-rw-r--r--test/lisp/tab-bar-tests.el17
1 files changed, 10 insertions, 7 deletions
diff --git a/test/lisp/tab-bar-tests.el b/test/lisp/tab-bar-tests.el
index 06a52ed42b1..257f6bd37d3 100644
--- a/test/lisp/tab-bar-tests.el
+++ b/test/lisp/tab-bar-tests.el
@@ -52,13 +52,16 @@
52 (tab-bar-tabs-set nil)) 52 (tab-bar-tabs-set nil))
53 53
54(ert-deftest tab-bar-tests-quit-restore-window () 54(ert-deftest tab-bar-tests-quit-restore-window ()
55 ;; Emba runs the container without "--tty" 55 (skip-when (pcase system-type
56 ;; (the environment variable "TERM" is nil), and this 56 ;; Skip test on MS-Windows in batch mode, since terminal
57 ;; test fails with '(error "Could not open file: /dev/tty")'. 57 ;; frames cannot be created in that case.
58 ;; Therefore skip it unless it can use '(tty-type . "linux")'. 58 ('windows-nt noninteractive)
59 (skip-unless (or (and (eq system-type 'gnu/linux) (getenv "TERM")) 59 ;; Emba runs the container without "--tty"
60 (and (not noninteractive) 60 ;; (the environment variable "TERM" is nil), and this
61 (eq system-type 'windows-nt)))) 61 ;; test fails with '(error "Could not open file: /dev/tty")'.
62 ;; Therefore skip it unless it can use '(tty-type . "linux")'.
63 ('gnu/linux (null (getenv "TERM")))))
64
62 (let* ((frame-params (when noninteractive 65 (let* ((frame-params (when noninteractive
63 '((window-system . nil) 66 '((window-system . nil)
64 (tty-type . "linux")))) 67 (tty-type . "linux"))))