about summary refs log tree commit diff
path: root/tests/tarball.sh
diff options
context:
space:
mode:
authorEelco Dolstra <eelco.dolstra@logicblox.com>2015-06-01T14·18+0200
committerEelco Dolstra <eelco.dolstra@logicblox.com>2015-06-01T14·18+0200
commitbc51175dc0c5f5e2106e73779663e9942dd451c4 (patch)
tree167d524816bd16c9678e5cf7d199559db0e55668 /tests/tarball.sh
parentda196ec68f8b34e0c4c7ee32beb9073b31b1531e (diff)
Add tarball tests
Diffstat (limited to 'tests/tarball.sh')
-rw-r--r--tests/tarball.sh20
1 files changed, 20 insertions, 0 deletions
diff --git a/tests/tarball.sh b/tests/tarball.sh
new file mode 100644
index 000000000000..6d02544cfae3
--- /dev/null
+++ b/tests/tarball.sh
@@ -0,0 +1,20 @@
+source common.sh
+
+clearStore
+
+tarroot=$TEST_ROOT/tarball
+rm -rf $tarroot
+mkdir -p $tarroot
+cp dependencies.nix $tarroot/default.nix
+cp config.nix dependencies.builder*.sh $tarroot/
+
+tarball=$TEST_ROOT/tarball.tar.xz
+(cd $TEST_ROOT && tar c tarball) | xz > $tarball
+
+nix-env -f file://$tarball -qa --out-path | grep -q dependencies
+
+nix-build file://$tarball
+
+nix-build '<foo>' -I foo=file://$tarball
+
+nix-build -E "import (fetchTarball file://$tarball)"