aboutsummaryrefslogtreecommitdiff
path: root/tests/fetchClosure.sh
diff options
context:
space:
mode:
Diffstat (limited to 'tests/fetchClosure.sh')
-rw-r--r--tests/fetchClosure.sh12
1 files changed, 12 insertions, 0 deletions
diff --git a/tests/fetchClosure.sh b/tests/fetchClosure.sh
index 0c905ac43..96e4bb741 100644
--- a/tests/fetchClosure.sh
+++ b/tests/fetchClosure.sh
@@ -56,3 +56,15 @@ nix copy --to file://$cacheDir $caPath
fromPath = $caPath;
}
") = $caPath ]]
+
+# Check that URL query parameters aren't allowed.
+clearStore
+narCache=$TEST_ROOT/nar-cache
+rm -rf $narCache
+(! nix eval -v --raw --expr "
+ builtins.fetchClosure {
+ fromStore = \"file://$cacheDir?local-nar-cache=$narCache\";
+ fromPath = $caPath;
+ }
+")
+(! [ -e $narCache ])