diff options
author | Ludovic Courtès <ludo@gnu.org> | 2019-09-24 10:11:38 +0200 |
---|---|---|
committer | Ludovic Courtès <ludo@gnu.org> | 2019-09-24 10:11:38 +0200 |
commit | 11da634a6e64afa2904542e2174aa2a185f9ac3a (patch) | |
tree | 5aeb8e6bd01761813650067af492b1c336886e34 /tests/containers.scm | |
parent | e5efdbce21a0afcbb3e73cc7b59111ccf62cb532 (diff) | |
parent | 7b3f56f5d7f4d2bb936e1579ed442e7f5b080abd (diff) | |
download | patches-11da634a6e64afa2904542e2174aa2a185f9ac3a.tar patches-11da634a6e64afa2904542e2174aa2a185f9ac3a.tar.gz |
Merge branch 'master' into core-updates
Diffstat (limited to 'tests/containers.scm')
-rw-r--r-- | tests/containers.scm | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/tests/containers.scm b/tests/containers.scm index c6c738f234..01fbcbb45a 100644 --- a/tests/containers.scm +++ b/tests/containers.scm @@ -269,4 +269,31 @@ (lset= string=? (cons* "." ".." (map basename reqs)) (pk (call-with-input-file result read)))))))))) +(test-assert "eval/container, non-empty load path" + (call-with-temporary-directory + (lambda (directory) + (define store + (open-connection-for-tests)) + (define result + (string-append directory "/r")) + (define requisites* + (store-lift requisites)) + + (mkdir result) + (run-with-store store + (mlet %store-monad ((status (eval/container + (with-imported-modules '((guix build utils)) + #~(begin + (use-modules (guix build utils)) + (mkdir-p "/result/a/b/c"))) + #:mappings + (list (file-system-mapping + (source result) + (target "/result") + (writable? #t)))))) + (close-connection store) + (return (and (zero? status) + (file-is-directory? + (string-append result "/a/b/c"))))))))) + (test-end) |