summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--gnu/tests/networking.scm24
1 files changed, 8 insertions, 16 deletions
diff --git a/gnu/tests/networking.scm b/gnu/tests/networking.scm
index a8358c6a55..a192c7e655 100644
--- a/gnu/tests/networking.scm
+++ b/gnu/tests/networking.scm
@@ -412,8 +412,6 @@ subnet 192.168.1.0 netmask 255.255.255.0 {
(with-imported-modules '((gnu build marionette))
#~(begin
(use-modules (gnu build marionette)
- (ice-9 popen)
- (ice-9 rdelim)
(srfi srfi-64))
(define marionette
@@ -423,16 +421,15 @@ subnet 192.168.1.0 netmask 255.255.255.0 {
(test-begin "dhcpd")
(test-assert "pid file exists"
- (marionette-eval
- '(file-exists?
- #$(dhcpd-configuration-pid-file dhcpd-v4-configuration))
+ (wait-for-file
+ '#$(dhcpd-configuration-pid-file dhcpd-v4-configuration)
marionette))
(test-assert "lease file exists"
- (marionette-eval
- '(file-exists?
- #$(dhcpd-configuration-lease-file dhcpd-v4-configuration))
- marionette))
+ (wait-for-file
+ '#$(dhcpd-configuration-lease-file dhcpd-v4-configuration)
+ marionette
+ #:read '(@ (ice-9 textual-ports) get-string-all)))
(test-assert "run directory exists"
(marionette-eval
@@ -443,13 +440,8 @@ subnet 192.168.1.0 netmask 255.255.255.0 {
(test-assert "dhcpd is alive"
(marionette-eval
'(begin
- (use-modules (gnu services herd)
- (srfi srfi-1))
- (live-service-running
- (find (lambda (live)
- (memq 'dhcpv4-daemon
- (live-service-provision live)))
- (current-services))))
+ (use-modules (gnu services herd))
+ (wait-for-service 'dhcpv4-daemon))
marionette))
(test-end))))