diff options
author | Ludovic Courtès <ludo@gnu.org> | 2015-03-25 10:52:52 +0100 |
---|---|---|
committer | Ludovic Courtès <ludo@gnu.org> | 2015-03-25 10:52:52 +0100 |
commit | 25d5b708a636ecf779035f75ad110574fc0262b9 (patch) | |
tree | 7d8429a59b7523d79790c5f4cdb5b96fabe8494e /tests/gexp.scm | |
parent | 17287d7d47567aa1649250182e0f7ab11d5d55d1 (diff) | |
parent | 614c2188420a266ec512c9c04af3bb2ea46c4dc4 (diff) | |
download | patches-25d5b708a636ecf779035f75ad110574fc0262b9.tar patches-25d5b708a636ecf779035f75ad110574fc0262b9.tar.gz |
Merge branch 'master' into core-updates
Diffstat (limited to 'tests/gexp.scm')
-rw-r--r-- | tests/gexp.scm | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/tests/gexp.scm b/tests/gexp.scm index 4c31e22f15..0540969503 100644 --- a/tests/gexp.scm +++ b/tests/gexp.scm @@ -160,6 +160,12 @@ (equal? `(list ,guile ,cu ,libc ,bu) (gexp->sexp* exp target))))) +(test-equal "ungexp + ungexp-native, nested" + (list `((,%bootstrap-guile "out")) '<> `((,coreutils "out"))) + (let* ((exp (gexp (list (ungexp-native (gexp (ungexp coreutils))) + (ungexp %bootstrap-guile))))) + (list (gexp-inputs exp) '<> (gexp-native-inputs exp)))) + (test-assert "input list" (let ((exp (gexp (display '(ungexp (list %bootstrap-guile coreutils))))) @@ -497,6 +503,23 @@ (list "out" %bootstrap-guile)))) (built-derivations (list drv)))) +(test-assertm "gexp->derivation #:allowed-references, specific output" + (mlet* %store-monad ((in (gexp->derivation "thing" + #~(begin + (mkdir #$output:ok) + (mkdir #$output:not-ok)))) + (drv (gexp->derivation "allowed-refs" + #~(begin + (pk #$in:not-ok) + (mkdir #$output) + (chdir #$output) + (symlink #$output "self") + (symlink #$in:ok "ok")) + #:allowed-references + (list "out" + (gexp-input in "ok"))))) + (built-derivations (list drv)))) + (test-assert "gexp->derivation #:allowed-references, disallowed" (let ((drv (run-with-store %store (gexp->derivation "allowed-refs" |