mirror of
https://github.com/NixOS/nix
synced 2025-06-27 00:11:17 +02:00
tests: derivation-advanced-attributes unset NIX_STORE
when built by nix, NIX_STORE is set, which breaks $got when it is not the default /nix/store
This commit is contained in:
parent
a8a572b11b
commit
d1894f3456
1 changed files with 1 additions and 1 deletions
|
@ -13,7 +13,7 @@ badExitCode=0
|
||||||
store="$TEST_ROOT/store"
|
store="$TEST_ROOT/store"
|
||||||
|
|
||||||
for nixFile in derivation/*.nix; do
|
for nixFile in derivation/*.nix; do
|
||||||
drvPath=$(nix-instantiate --store "$store" --pure-eval --expr "$(< "$nixFile")")
|
drvPath=$(env -u NIX_STORE nix-instantiate --store "$store" --pure-eval --expr "$(< "$nixFile")")
|
||||||
testName=$(basename "$nixFile" .nix)
|
testName=$(basename "$nixFile" .nix)
|
||||||
got="${store}${drvPath}"
|
got="${store}${drvPath}"
|
||||||
expected="derivation/$testName.drv"
|
expected="derivation/$testName.drv"
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue