From 0b6af195fe7476a15e498b24c67f9d8f6080a400 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ludovic=20Court=C3=A8s?= Date: Fri, 9 Jan 2015 23:33:42 +0100 Subject: derivations: Add 'derivation-output-names'. * guix/derivations.scm (derivation-output-names): New procedure. (derivation-prerequisites-to-build): Use it for #:outputs. (map-derivation): Likewise. * tests/derivations.scm ("derivation-output-names"): New test. --- tests/derivations.scm | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'tests') diff --git a/tests/derivations.scm b/tests/derivations.scm index 4b36758c25..25e6f75657 100644 --- a/tests/derivations.scm +++ b/tests/derivations.scm @@ -1,5 +1,5 @@ ;;; GNU Guix --- Functional package management for GNU -;;; Copyright © 2012, 2013, 2014 Ludovic Courtès +;;; Copyright © 2012, 2013, 2014, 2015 Ludovic Courtès ;;; ;;; This file is part of GNU Guix. ;;; @@ -178,6 +178,14 @@ (let ((drv (derivation %store "foo-0.0" %bash '()))) (derivation-name drv))) +(test-equal "derivation-output-names" + '(("out") ("bar" "chbouib")) + (let ((drv1 (derivation %store "foo-0.0" %bash '())) + (drv2 (derivation %store "foo-0.0" %bash '() + #:outputs '("bar" "chbouib")))) + (list (derivation-output-names drv1) + (derivation-output-names drv2)))) + (test-assert "offloadable-derivation?" (and (offloadable-derivation? (derivation %store "foo" %bash '())) (not (offloadable-derivation? -- cgit v1.2.3