guix-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[shepherd] 02/03: tests: Skip test requiring suspendable 'read' on Guile


From: Ludovic Courtès
Subject: [shepherd] 02/03: tests: Skip test requiring suspendable 'read' on Guile 2.2.
Date: Fri, 9 Sep 2022 11:48:02 -0400 (EDT)

civodul pushed a commit to branch master
in repository shepherd.

commit 44ca10f086209c5377fd7937785cd956a2b5d8c7
Author: Ludovic Courtès <ludo@gnu.org>
AuthorDate: Fri Sep 9 11:15:53 2022 +0200

    tests: Skip test requiring suspendable 'read' on Guile 2.2.
    
    This is a followup to eb275516157f7a664844b3b657d18761932803b5.
    
    * tests/misbehaved-client.sh: Skip last 'read' test on Guile 2.x.
---
 tests/misbehaved-client.sh | 11 +++++++++--
 1 file changed, 9 insertions(+), 2 deletions(-)

diff --git a/tests/misbehaved-client.sh b/tests/misbehaved-client.sh
index 18a064f..00e7d8f 100644
--- a/tests/misbehaved-client.sh
+++ b/tests/misbehaved-client.sh
@@ -76,7 +76,13 @@ $herd status                 # still here?
 
 $herd status
 
-"$GUILE" -c "
+if "$GUILE" -c '(exit (string=? "2" (major-version)))'
+then
+    # The 'read' procedure in Guile 2.2 is not suspendable.  Thus, the test
+    # below would hang forever in 'scm_read'.
+    echo "Running on Guile 2.x; skipping test that requires suspendable 
'read'." >&2
+else
+    "$GUILE" -c "
 (use-modules (shepherd comm) (shepherd support) (ice-9 match))
 
 (let ((sock (open-connection \"$socket\")))
@@ -91,6 +97,7 @@ $herd status
        (pk 'wrong x)
        (exit 1)))))"
 
-$herd status
+    $herd status
+fi
 
 cat "$log"



reply via email to

[Prev in Thread] Current Thread [Next in Thread]