1
0
Fork 0
mirror of https://github.com/NixOS/nix synced 2025-07-12 19:05:08 +02:00

* Clean up some tests (use nix-build where appropriate).

This commit is contained in:
Eelco Dolstra 2009-03-18 13:15:55 +00:00
parent 93b6926054
commit 1dcf208f56
7 changed files with 25 additions and 34 deletions

View file

@ -1,16 +1,17 @@
source common.sh
$nixstore --gc
clearStore
# Produce an escaped log file.
$nixstore --log-type escapes -r -vv $($nixinstantiate dependencies.nix) 2> $TEST_ROOT/log.esc
set -x
$nixbuild --log-type escapes -vv dependencies.nix 2> $TEST_ROOT/log.esc
# Convert it to an XML representation.
$TOP/src/nix-log2xml/nix-log2xml < $TEST_ROOT/log.esc > $TEST_ROOT/log.xml
# Is this well-formed XML?
if test "$xmllint" != "false"; then
$xmllint $xmlflags --noout $TEST_ROOT/log.xml
$xmllint $xmlflags --noout $TEST_ROOT/log.xml || fail "malformed XML"
fi
# Convert to HTML.
@ -19,5 +20,5 @@ if test "$xsltproc" != "false"; then
# Ideally we would check that the generated HTML is valid...
# A few checks...
grep "<li>.*<code>.*FOO" $TEST_ROOT/log.html
grep "<code>.*FOO" $TEST_ROOT/log.html || fail "bad HTML output"
fi