diff options
author | Mark H Weaver <mhw@netris.org> | 2016-07-29 14:18:07 -0400 |
---|---|---|
committer | Mark H Weaver <mhw@netris.org> | 2016-07-29 14:18:07 -0400 |
commit | 0bab3af0786ffd4caec05a29d7281ac5e5c18b6b (patch) | |
tree | d83fd52d0cb72b3a9c21642583d804c8c1865646 /tests | |
parent | 49d725a108dc33f4eb72faff7cf138c5dd8c64f4 (diff) | |
parent | 682a7d23385f709a680049a823bb84e45c922b3c (diff) | |
download | guix-0bab3af0786ffd4caec05a29d7281ac5e5c18b6b.tar.gz |
Merge branch 'master' into core-updates
Diffstat (limited to 'tests')
-rw-r--r-- | tests/guix-register.sh | 18 |
1 files changed, 15 insertions, 3 deletions
diff --git a/tests/guix-register.sh b/tests/guix-register.sh index 360cf55979..521735b8a4 100644 --- a/tests/guix-register.sh +++ b/tests/guix-register.sh @@ -1,5 +1,5 @@ # GNU Guix --- Functional package management for GNU -# Copyright © 2013, 2014, 2015 Ludovic Courtès <ludo@gnu.org> +# Copyright © 2013, 2014, 2015, 2016 Ludovic Courtès <ludo@gnu.org> # # This file is part of GNU Guix. # @@ -157,8 +157,20 @@ do # that name in a 'valid-path?' query because 'assertStorePath' would kill # us because of the wrong prefix. So we just list dead paths instead. guile -c " - (use-modules (guix store) (srfi srfi-1)) - (define s (open-connection \"$GUIX_DAEMON_SOCKET\")) + (use-modules (guix store) (srfi srfi-1) (srfi srfi-34)) + + (define s + (let loop ((i 5)) + (guard (c ((nix-connection-error? c) + (if (<= i 0) + (raise c) + (begin + (display \"waiting for daemon socket...\") + (newline) + (sleep 1) + (loop (- i 1)))))) + (open-connection \"$GUIX_DAEMON_SOCKET\")))) + (exit (lset= string=? (pk 1 (list \"$copied\" \"$copied_duplicate1\" \"$copied_duplicate2\")) |