summary refs log tree commit diff
path: root/gnu/tests/networking.scm
diff options
context:
space:
mode:
Diffstat (limited to 'gnu/tests/networking.scm')
-rw-r--r--gnu/tests/networking.scm42
1 files changed, 12 insertions, 30 deletions
diff --git a/gnu/tests/networking.scm b/gnu/tests/networking.scm
index 246e0a15fa..2bcc7f70dc 100644
--- a/gnu/tests/networking.scm
+++ b/gnu/tests/networking.scm
@@ -197,9 +197,7 @@ port 7, and a dict service on port 2628."
           (define marionette
             (make-marionette (list #$vm)))
 
-          (mkdir #$output)
-          (chdir #$output)
-
+          (test-runner-current (system-test-runner #$output))
           (test-begin "inetd")
 
           ;; Make sure the PID file is created.
@@ -230,8 +228,7 @@ port 7, and a dict service on port 2628."
                 (close dict)
                 response)))
 
-          (test-end)
-          (exit (= (test-runner-fail-count (test-runner-current)) 0)))))
+          (test-end))))
 
   (gexp->derivation "inetd-test" test))
 
@@ -304,9 +301,7 @@ port 7, and a dict service on port 2628."
           (define marionette
             (make-marionette (list #$(virtual-machine os))))
 
-          (mkdir #$output)
-          (chdir #$output)
-
+          (test-runner-current (system-test-runner #$output))
           (test-begin "openvswitch")
 
           ;; Make sure the bridge is created.
@@ -356,8 +351,7 @@ port 7, and a dict service on port 2628."
                   (logand flags IFF_UP)))
              marionette))
 
-          (test-end)
-          (exit (= (test-runner-fail-count (test-runner-current)) 0)))))
+          (test-end))))
 
   (gexp->derivation "openvswitch-test" test))
 
@@ -421,9 +415,7 @@ subnet 192.168.1.0 netmask 255.255.255.0 {
           (define marionette
             (make-marionette (list #$(virtual-machine os))))
 
-          (mkdir #$output)
-          (chdir #$output)
-
+          (test-runner-current (system-test-runner #$output))
           (test-begin "dhcpd")
 
           (test-assert "pid file exists"
@@ -456,8 +448,7 @@ subnet 192.168.1.0 netmask 255.255.255.0 {
                        (current-services))))
              marionette))
 
-          (test-end)
-          (exit (= (test-runner-fail-count (test-runner-current)) 0)))))
+          (test-end))))
 
   (gexp->derivation "dhcpd-test" test))
 
@@ -516,9 +507,7 @@ subnet 192.168.1.0 netmask 255.255.255.0 {
                        (current-services))))
              marionette))
 
-          (mkdir #$output)
-          (chdir #$output)
-
+          (test-runner-current (system-test-runner #$output))
           (test-begin "tor")
 
           ;; Test the usual Tor service.
@@ -550,8 +539,7 @@ subnet 192.168.1.0 netmask 255.255.255.0 {
               (wait-for-unix-socket "/var/run/tor/socks-sock"
                                     marionette/unix-socks-socket)))
 
-          (test-end)
-          (exit (= (test-runner-fail-count (test-runner-current)) 0)))))
+          (test-end))))
 
   (gexp->derivation "tor-test" test))
 
@@ -643,9 +631,7 @@ COMMIT
                            (loop (read-line in)))))))))
              marionette))
 
-          (mkdir #$output)
-          (chdir #$output)
-
+          (test-runner-current (system-test-runner #$output))
           (test-begin "iptables")
 
           (test-equal "iptables-save dumps the same rules that were loaded"
@@ -674,8 +660,7 @@ COMMIT
           ;;      marionette)
           ;;     (wait-for-tcp-port inetd-echo-port marionette #:timeout 5)))
 
-          (test-end)
-          (exit (= (test-runner-fail-count (test-runner-current)) 0)))))
+          (test-end))))
 
   (gexp->derivation "iptables" test))
 
@@ -739,9 +724,7 @@ COMMIT
              marionette))
 
           (marionette-eval '(use-modules (guix ipfs)) marionette)
-          (mkdir #$output)
-          (chdir #$output)
-
+          (test-runner-current (system-test-runner #$output))
           (test-begin "ipfs")
 
           ;; Test the IPFS service.
@@ -761,8 +744,7 @@ COMMIT
             test-bv
             (read-contents (add-data test-bv)))
 
-          (test-end)
-          (exit (= (test-runner-fail-count (test-runner-current)) 0)))))
+          (test-end))))
   (gexp->derivation "ipfs-test" test))
 
 (define %test-ipfs