aboutsummaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorJohn Ericson <John.Ericson@Obsidian.Systems>2020-08-28 22:03:54 +0000
committerJohn Ericson <John.Ericson@Obsidian.Systems>2020-08-28 22:03:54 +0000
commit4db0010a9374e357de3db3c0cf1cb1b490a14727 (patch)
treee5204c62d0b1eefe5c05d7552c5e9f9a67227b85 /tests
parent02e0001fc09e00f1d70c962757536630a5cb9c6c (diff)
Test CA derivation input caching
Diffstat (limited to 'tests')
-rw-r--r--tests/content-addressed.sh5
1 files changed, 4 insertions, 1 deletions
diff --git a/tests/content-addressed.sh b/tests/content-addressed.sh
index 522310585..5997a432f 100644
--- a/tests/content-addressed.sh
+++ b/tests/content-addressed.sh
@@ -9,10 +9,13 @@ testDerivation () {
local derivationPath=$1
local commonArgs=("--experimental-features" "ca-derivations" "./content-addressed.nix" "-A" "$derivationPath" "--no-out-link")
local out1=$(nix-build "${commonArgs[@]}" --arg seed 1)
- local out2=$(nix-build "${commonArgs[@]}" --arg seed 2)
+ local out2=$(nix-build "${commonArgs[@]}" --arg seed 2 "${extraArgs[@]}")
test $out1 == $out2
}
testDerivation root
+# The seed only changes the root derivation, and not it's output, so the
+# dependent derivations should only need to be built once.
+extaArgs=(-j0)
testDerivation dependent
testDerivation transitivelyDependent