aboutsummaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
Diffstat (limited to 'tests')
-rw-r--r--tests/gexp.scm14
1 files changed, 12 insertions, 2 deletions
diff --git a/tests/gexp.scm b/tests/gexp.scm
index 3da5b82e4c..21606b510b 100644
--- a/tests/gexp.scm
+++ b/tests/gexp.scm
@@ -21,8 +21,7 @@
#:use-module (guix monads)
#:use-module (guix gexp)
#:use-module (guix derivations)
- #:use-module ((guix packages)
- #:select (package-derivation %current-system))
+ #:use-module (guix packages)
#:use-module (gnu packages)
#:use-module (gnu packages base)
#:use-module (gnu packages bootstrap)
@@ -83,6 +82,17 @@
(package-derivation %store coreutils)))
(gexp->sexp* exp)))))
+(test-assert "one input origin"
+ (let ((exp (gexp (display (ungexp (package-source coreutils))))))
+ (and (gexp? exp)
+ (match (gexp-inputs exp)
+ (((o "out"))
+ (eq? o (package-source coreutils))))
+ (equal? `(display ,(derivation->output-path
+ (package-source-derivation
+ %store (package-source coreutils))))
+ (gexp->sexp* exp)))))
+
(test-assert "same input twice"
(let ((exp (gexp (begin
(display (ungexp coreutils))