guix-commits
[Top][All Lists]
Advanced

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

02/06: tests: inetd: Avoid race condition when looking for PID file.


From: guix-commits
Subject: 02/06: tests: inetd: Avoid race condition when looking for PID file.
Date: Sun, 5 Nov 2023 17:26:16 -0500 (EST)

civodul pushed a commit to branch master
in repository guix.

commit 31b39f2a336270048574ede1ed1619ff11f95a0a
Author: Ludovic Courtès <ludo@gnu.org>
AuthorDate: Sun Nov 5 18:04:16 2023 +0100

    tests: inetd: Avoid race condition when looking for PID file.
    
    * gnu/tests/networking.scm (run-inetd-test): Use ‘wait-for-file’ instead
    of ‘file-exists?’.
    
    Change-Id: I3e596814485428fb81595d81c4e03519340c6576
---
 gnu/tests/networking.scm | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/gnu/tests/networking.scm b/gnu/tests/networking.scm
index 52f818af48..b1ab43efb6 100644
--- a/gnu/tests/networking.scm
+++ b/gnu/tests/networking.scm
@@ -349,9 +349,8 @@ port 7, and a dict service on port 2628."
 
           ;; Make sure the PID file is created.
           (test-assert "PID file"
-            (marionette-eval
-             '(file-exists? "/var/run/inetd.pid")
-             marionette))
+            (wait-for-file "/var/run/inetd.pid" marionette
+                           #:timeout 30))
 
           ;; Test the echo service.
           (test-equal "echo response"



reply via email to

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