aboutsummaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorLudovic Courtès <ludo@gnu.org>2013-11-12 01:06:25 +0100
committerLudovic Courtès <ludo@gnu.org>2013-11-12 01:06:45 +0100
commitbf4211523baf8ab1c853aac48ef0324f8f704510 (patch)
treec31db97ccececd3f3ac48396fa65227359723598 /tests
parenteddd4077a5292052d95443078ee4db9f34f2f0e2 (diff)
downloadpatches-bf4211523baf8ab1c853aac48ef0324f8f704510.tar
patches-bf4211523baf8ab1c853aac48ef0324f8f704510.tar.gz
guix build: Add '--log-file'.
* guix/scripts/build.scm (show-help): Add '--log-file'. (%options): Likewise. (guix-build): Set %FILE-PORT-NAME-CANONICALIZATION. Honor '--log-file'. * tests/guix-build.sh: Add '--log-file' tests. * doc/guix.texi (Invoking guix build): Document '--log-file'.
Diffstat (limited to 'tests')
-rw-r--r--tests/guix-build.sh11
1 files changed, 11 insertions, 0 deletions
diff --git a/tests/guix-build.sh b/tests/guix-build.sh
index 83de9f5285..e228b38616 100644
--- a/tests/guix-build.sh
+++ b/tests/guix-build.sh
@@ -36,6 +36,17 @@ guix build -e '(@@ (gnu packages base) %bootstrap-guile)' | \
guix build hello -d | \
grep -e '-hello-[0-9\.]\+\.drv$'
+# Should all return valid log files.
+drv="`guix build -d -e '(@@ (gnu packages base) %bootstrap-guile)'`"
+out="`guix build -e '(@@ (gnu packages base) %bootstrap-guile)'`"
+log="`guix build --log-file $drv`"
+echo "$log" | grep log/.*guile.*drv
+test -f "$log"
+test "`guix build -e '(@@ (gnu packages base) %bootstrap-guile)' --log-file`" \
+ = "$log"
+test "`guix build --log-file guile-bootstrap`" = "$log"
+test "`guix build --log-file $out`" = "$log"
+
# Should fail because the name/version combination could not be found.
if guix build hello-0.0.1 -n; then false; else true; fi