From e8db1d44db972b4a9f6ed7a882d4072106862f99 Mon Sep 17 00:00:00 2001 From: Paul Eggert Date: Wed, 22 Jan 2025 11:03:08 -0800 Subject: [PATCH] Port allows-stdout test to overly-suspicious bwrap * test/src/emacs-tests.el (emacs-tests/bwrap/allows-stdout): Skip test if bwrap prohibits even "echo Hi", which it does on my Ubuntu 24.10 platform. This extra check means we no longer need to test separately whether the filter is readable. (cherry picked from commit 34166dcf9cbd961d4f53ce9029e179a21a12c001) --- test/src/emacs-tests.el | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/test/src/emacs-tests.el b/test/src/emacs-tests.el index a3c97279d50..a8f7097014e 100644 --- a/test/src/emacs-tests.el +++ b/test/src/emacs-tests.el @@ -183,7 +183,13 @@ (skip-unless bash) (skip-unless bwrap) (skip-unless (file-executable-p emacs)) - (skip-unless (file-readable-p filter)) + (skip-unless + (let ((command + (concat + (shell-quote-argument (file-name-unquote bwrap)) + " --ro-bind / / --seccomp 20 -- echo Hi 20< " + (shell-quote-argument (file-name-unquote filter))))) + (zerop (call-process bash nil nil nil "-c" command)))) (should-not (file-remote-p bwrap)) (should-not (file-remote-p emacs)) (should-not (file-remote-p filter)) -- 2.39.5