diff options
author | Dan Peebles <pumpkingod@gmail.com> | 2015-04-20 00:34:29 -0400 |
---|---|---|
committer | Dan Peebles <pumpkingod@gmail.com> | 2015-04-20 00:34:29 -0400 |
commit | 8a84bd8c8bda1e4c6764c10ecdef9d74e4884800 (patch) | |
tree | a901eb32c7b6661f6915e021e045f22e2307e856 /tests | |
parent | 4d652875bdd87c3f1aa08111c63c0719f1ee0c1a (diff) |
Support tarballs in nix channel URLs
Diffstat (limited to 'tests')
-rw-r--r-- | tests/nix-channel.sh | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/tests/nix-channel.sh b/tests/nix-channel.sh index a25d56bec..0114566d7 100644 --- a/tests/nix-channel.sh +++ b/tests/nix-channel.sh @@ -41,3 +41,26 @@ grep -q 'item.*attrPath="foo".*name="dependencies"' $TEST_ROOT/meta.xml # Do an install. nix-env -i dependencies [ -e $TEST_ROOT/var/nix/profiles/default/foobar ] + + + +clearProfiles +clearManifests +rm -f $TEST_ROOT/.nix-channels + +# Test updating from a tarball +nix-channel --add file://$TEST_ROOT/foo/nixexprs.tar.bz2 +nix-channel --update + +# Do a query. +nix-env -qa \* --meta --xml --out-path > $TEST_ROOT/meta.xml +if [ "$xmllint" != false ]; then + $xmllint --noout $TEST_ROOT/meta.xml || fail "malformed XML" +fi +grep -q 'meta.*description.*Random test package' $TEST_ROOT/meta.xml +grep -q 'item.*attrPath="foo".*name="dependencies"' $TEST_ROOT/meta.xml + +# Do an install. +nix-env -i dependencies +[ -e $TEST_ROOT/var/nix/profiles/default/foobar ] + |