diff options
author | John Ericson <John.Ericson@Obsidian.Systems> | 2022-12-12 17:40:49 -0500 |
---|---|---|
committer | John Ericson <John.Ericson@Obsidian.Systems> | 2022-12-12 17:40:49 -0500 |
commit | 5273cf4c9743ce7a39646229029618640ceb35c3 (patch) | |
tree | cecefa6c719f445d782aa8c45b920f5de7fa582d /tests/lang.sh | |
parent | dabb03b8d0ee0155ef994042ef807e0924b9e6e7 (diff) | |
parent | edb54c62e6c66f3d26642c024d92bd20b30abf85 (diff) |
Merge remote-tracking branch 'upstream/master' into indexed-store-path-outputs
Diffstat (limited to 'tests/lang.sh')
-rw-r--r-- | tests/lang.sh | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/tests/lang.sh b/tests/lang.sh index c0b0fc58c..95e795e2e 100644 --- a/tests/lang.sh +++ b/tests/lang.sh @@ -2,6 +2,7 @@ source common.sh export TEST_VAR=foo # for eval-okay-getenv.nix export NIX_REMOTE=dummy:// +export NIX_STORE_DIR=/nix/store nix-instantiate --eval -E 'builtins.trace "Hello" 123' 2>&1 | grep -q Hello nix-instantiate --eval -E 'builtins.addErrorContext "Hello" 123' 2>&1 @@ -50,10 +51,10 @@ for i in lang/eval-okay-*.nix; do if test -e lang/$i.flags; then flags=$(cat lang/$i.flags) fi - if ! expect 0 env NIX_PATH=lang/dir3:lang/dir4 nix-instantiate $flags --eval --strict lang/$i.nix > lang/$i.out; then + if ! expect 0 env NIX_PATH=lang/dir3:lang/dir4 HOME=/fake-home nix-instantiate $flags --eval --strict lang/$i.nix > lang/$i.out; then echo "FAIL: $i should evaluate" fail=1 - elif ! diff lang/$i.out lang/$i.exp; then + elif ! diff <(< lang/$i.out sed -e "s|$(pwd)|/pwd|g") lang/$i.exp; then echo "FAIL: evaluation result of $i not as expected" fail=1 fi |