[Top][All Lists]

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

01/01: tests: Make #:references-graphs gexp test more tolerant.

From: Ludovic Courtès
Subject: 01/01: tests: Make #:references-graphs gexp test more tolerant.
Date: Mon, 20 Jul 2015 11:38:06 +0000

civodul pushed a commit to branch master
in repository guix.

commit 72cd8ec0b1465ddf5465bc2d75b3ca343aad99dd
Author: Ludovic Courtès <address@hidden>
Date:   Mon Jul 20 13:36:36 2015 +0200

    tests: Make #:references-graphs gexp test more tolerant.
    * tests/gexp.scm ("gexp->derivation #:references-graphs"): Use 'lset=' 
      of 'equal?' since the order in which references are listed in not
 tests/gexp.scm |   12 +++++++-----
 1 files changed, 7 insertions(+), 5 deletions(-)

diff --git a/tests/gexp.scm b/tests/gexp.scm
index 740d746..0749811 100644
--- a/tests/gexp.scm
+++ b/tests/gexp.scm
@@ -511,7 +511,7 @@
 (test-assertm "gexp->derivation #:references-graphs"
   (mlet* %store-monad
-      ((one (text-file "one" "hello, world"))
+      ((one (text-file "one" (random-text)))
        (two (gexp->derivation "two"
                               #~(symlink #$one #$output:chbouib)))
        (drv (gexp->derivation "ref-graphs"
@@ -544,12 +544,14 @@
        (g-guile -> (derivation->output-path drv)))
     (return (and ok?
                  (equal? (call-with-input-file g-one read) (list one))
-                 (equal? (call-with-input-file g-two read)
-                         (list one (derivation->output-path two "chbouib")))
+                 (lset= string=?
+                        (call-with-input-file g-two read)
+                        (list one (derivation->output-path two "chbouib")))
                  ;; Note: %BOOTSTRAP-GUILE depends on the bootstrap Bash.
-                 (equal? (call-with-input-file g-guile read)
-                         (list (derivation->output-path guile-drv) bash))))))
+                 (lset= string=?
+                        (call-with-input-file g-guile read)
+                        (list (derivation->output-path guile-drv) bash))))))
 (test-assertm "gexp->derivation #:allowed-references"
   (mlet %store-monad ((drv (gexp->derivation "allowed-refs"

reply via email to

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