diff options
author | Marius Bakke <mbakke@fastmail.com> | 2018-05-06 15:56:24 +0200 |
---|---|---|
committer | Marius Bakke <mbakke@fastmail.com> | 2018-05-06 15:56:24 +0200 |
commit | 12bd588346f8b2fb3709acfe0ee89d153da2db34 (patch) | |
tree | 459d8eb13a0508170ba462fe61a8b45fb55ea79f /tests/guix-build.sh | |
parent | 7d5adf013127c89826e9fbe9f1a67265b3538609 (diff) | |
parent | 8e020519b45bbdb9403164bd4403f2465bac99ad (diff) | |
download | guix-12bd588346f8b2fb3709acfe0ee89d153da2db34.tar guix-12bd588346f8b2fb3709acfe0ee89d153da2db34.tar.gz |
Merge branch 'master' into core-updates
Diffstat (limited to 'tests/guix-build.sh')
-rw-r--r-- | tests/guix-build.sh | 21 |
1 files changed, 20 insertions, 1 deletions
diff --git a/tests/guix-build.sh b/tests/guix-build.sh index b84723fa43..92e7299321 100644 --- a/tests/guix-build.sh +++ b/tests/guix-build.sh @@ -1,5 +1,5 @@ # GNU Guix --- Functional package management for GNU -# Copyright © 2012, 2013, 2014, 2016, 2017 Ludovic Courtès <ludo@gnu.org> +# Copyright © 2012, 2013, 2014, 2016, 2017, 2018 Ludovic Courtès <ludo@gnu.org> # # This file is part of GNU Guix. # @@ -138,6 +138,25 @@ test `guix build -d --sources=transitive foo \ | grep -e 'foo\.tar\.gz' -e 'bar\.tar\.gz' -e 'bar\.dat' \ | wc -l` -eq 3 + +# Unbound variables. +cat > "$module_dir/foo.scm"<<EOF +(define-module (foo) + #:use-module (guix tests) + #:use-module (guix build-system trivial)) + +(define-public foo + (dummy-package "package-with-something-wrong" + (build-system trivial-build-system) + (inputs (quasiquote (("sed" ,sed)))))) ;unbound variable +EOF + +if guix build package-with-something-wrong -n; then false; else true; fi +guix build package-with-something-wrong -n 2> "$module_dir/err" || true +grep "unbound" "$module_dir/err" # actual error +grep "forget.*(gnu packages base)" "$module_dir/err" # hint +rm -f "$module_dir"/* + # Should all return valid log files. drv="`guix build -d -e '(@@ (gnu packages bootstrap) %bootstrap-guile)'`" out="`guix build -e '(@@ (gnu packages bootstrap) %bootstrap-guile)'`" |