From 196f6fca44c8d39c3adf72b6cf1630335db43dd6 Mon Sep 17 00:00:00 2001 From: Michael Gran Date: Sun, 30 Mar 2025 20:01:25 -0700 Subject: [PATCH] popen.test: add shell on mingw --- test-suite/tests/popen.test | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/test-suite/tests/popen.test b/test-suite/tests/popen.test index b8dfbef13..aad7687b7 100644 --- a/test-suite/tests/popen.test +++ b/test-suite/tests/popen.test @@ -225,7 +225,6 @@ exec 2>~a; read REPLY" (close-pipe port) result)))))) - (with-test-prefix "open-pipe*" (pass-if-equal "OPEN_BOTH" @@ -281,11 +280,15 @@ exec 2>~a; read REPLY" (list (read-string from) (status:exit-val (cdr (waitpid pid)))))) -(pass-if-equal "piped-process" - 42 - (status:exit-val - (cdr (waitpid ((@@ (ice-9 popen) piped-process) - "./meta/guile" '("-c" "(exit 42)")))))) + (pass-if-equal "piped-process" + 42 + (status:exit-val + (cdr (waitpid + (if (not mingw?) + ((@@ (ice-9 popen) piped-process) "./meta/guile" '("-c" "(exit 42)")) + ;; Calling piped-process directly means that, on MinGW, + ;; /bin/sh is bypassed. + ((@@ (ice-9 popen) piped-process) "sh" '("./meta/guile" "-c" "(exit 42)"))))))) (pass-if-equal "piped-process: with output" '("foo bar\n" 0)