summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorArjan Adriaanse <arjan@adriaan.se>2022-01-02 18:20:45 +0100
committerLudovic Courtès <ludo@gnu.org>2022-01-05 23:44:18 +0100
commitd7fb57bcd559fc1fea60cbed91990c06462d33fb (patch)
tree55d52a522c90cebee7294d69e59b38bf871b8ba1 /tests
parent282197b52158764889bcc56955dc98940947d493 (diff)
downloadguix-patches-d7fb57bcd559fc1fea60cbed91990c06462d33fb.tar
guix-patches-d7fb57bcd559fc1fea60cbed91990c06462d33fb.tar.gz
home: import: Fix handling of manifest entries with specific output.
specification->package fails on manifest entries with specific outputs, resulting in an invalid home configuration. This changes the import command to use specification->package+output instead. * guix/scripts/home/import.scm (manifest+configuration-files->code): Make sure manifest entries with specific output are also handled. * tests/home-import.scm: Specify output in home environment manifest entry. Signed-off-by: Ludovic Courtès <ludo@gnu.org>
Diffstat (limited to 'tests')
-rw-r--r--tests/home-import.scm14
1 files changed, 8 insertions, 6 deletions
diff --git a/tests/home-import.scm b/tests/home-import.scm
index 0bcdf8a469..6d373acf79 100644
--- a/tests/home-import.scm
+++ b/tests/home-import.scm
@@ -1,5 +1,6 @@
;;; GNU Guix --- Functional package management for GNU
;;; Copyright © 2021 Xinglu Chen <public@yoctocell.xyz>
+;;; Copyright © 2022 Arjan Adriaanse <arjan@adriaan.se>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -52,7 +53,8 @@
(define gcc
(manifest-entry
(name "gcc")
- (version "10.3.0")
+ (version "")
+ (output "lib")
(item "/gnu/store/...")))
;; Helpers for checking and generating home environments.
@@ -101,8 +103,8 @@ corresponding file."
('gnu 'services))
('home-environment
('packages
- ('map 'specification->package
- ('list "guile@2.0.9" "gcc" "glibc@2.19")))
+ ('map ('compose 'list 'specification->package+output)
+ ('list "guile@2.0.9" "gcc:lib" "glibc@2.19")))
('services
('list)))))
@@ -118,7 +120,7 @@ corresponding file."
('home-environment
('packages
('list (transform ('specification->package "guile@2.0.9"))
- ('specification->package "gcc")
+ ('list ('specification->package "gcc") "lib")
('specification->package "glibc@2.19")))
('services ('list)))))
@@ -130,7 +132,7 @@ corresponding file."
('gnu 'services))
('home-environment
('packages
- ('map 'specification->package
+ ('map ('compose 'list 'specification->package+output)
('list)))
('services
('list)))))
@@ -145,7 +147,7 @@ corresponding file."
('gnu 'home 'services 'shells))
('home-environment
('packages
- ('map 'specification->package
+ ('map ('compose 'list 'specification->package+output)
('list)))
('services
('list ('service