aboutsummaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorLudovic Courtès <ludo@gnu.org>2013-11-01 12:59:31 +0100
committerLudovic Courtès <ludo@gnu.org>2013-11-01 12:59:31 +0100
commitff8061b59161592690ab6ea526282fae11d87676 (patch)
tree09f00df03ec0a1f4922376ba1a0cd4f443a305e4 /tests
parente50805251ae7386c2ddbd036885bcc4300cf336e (diff)
parentb645425f71a5a777e7658bbdac0e22e134d44db5 (diff)
downloadpatches-ff8061b59161592690ab6ea526282fae11d87676.tar
patches-ff8061b59161592690ab6ea526282fae11d87676.tar.gz
Merge branch 'master' into core-updates
Diffstat (limited to 'tests')
-rw-r--r--tests/derivations.scm17
-rw-r--r--tests/records.scm6
2 files changed, 20 insertions, 3 deletions
diff --git a/tests/derivations.scm b/tests/derivations.scm
index 4756fb9cba..1b32ab5ffd 100644
--- a/tests/derivations.scm
+++ b/tests/derivations.scm
@@ -260,6 +260,23 @@
(and (eq? 'one (call-with-input-file one read))
(eq? 'two (call-with-input-file two read)))))))
+(test-assert "multiple-output derivation, derivation-path->output-path"
+ (let* ((builder (add-text-to-store %store "builder.sh"
+ "echo one > $out ; echo two > $second"
+ '()))
+ (drv (derivation %store "multiple"
+ %bash `(,builder)
+ #:outputs '("out" "second")))
+ (drv-file (derivation-file-name drv))
+ (one (derivation->output-path drv "out"))
+ (two (derivation->output-path drv "second"))
+ (first (derivation-path->output-path drv-file "out"))
+ (second (derivation-path->output-path drv-file "second")))
+ (and (not (string=? one two))
+ (string-suffix? "-second" two)
+ (string=? first one)
+ (string=? second two))))
+
(test-assert "user of multiple-output derivation"
;; Check whether specifying several inputs coming from the same
;; multiple-output derivation works.
diff --git a/tests/records.scm b/tests/records.scm
index 851ff7bdef..15709ac326 100644
--- a/tests/records.scm
+++ b/tests/records.scm
@@ -36,9 +36,9 @@
(match (foo (bar 1))
(($ <foo> 1 42) #t)))))
-(test-assert "define-record-type* with letrec* behavior"
+(test-assert "define-record-type* with let* behavior"
;; Make sure field initializers can refer to each other as if they were in
- ;; a `letrec*'.
+ ;; a 'let*'.
(begin
(define-record-type* <bar> bar make-bar
foo?
@@ -69,7 +69,7 @@
(equal? c d)
(match e (($ <foo> 42 77) #t))))))
-(test-assert "define-record-type* & inherit & letrec* behavior"
+(test-assert "define-record-type* & inherit & let* behavior"
(begin
(define-record-type* <foo> foo make-foo
foo?