mirror of
https://github.com/privatevoid-net/nix-super.git
synced 2024-11-10 08:16:15 +02:00
Merge pull request #7404 from ncfavier/tmpdir-tests
tests: don't refer to TMPDIR
This commit is contained in:
commit
f4d6f3ae8f
2 changed files with 4 additions and 4 deletions
|
@ -44,7 +44,7 @@ with import ./config.nix;
|
|||
};
|
||||
|
||||
hashmismatch = import <nix/fetchurl.nix> {
|
||||
url = "file://" + builtins.getEnv "TMPDIR" + "/dummy";
|
||||
url = "file://" + builtins.getEnv "TEST_ROOT" + "/dummy";
|
||||
sha256 = "0mdqa9w1p6cmli6976v4wi0sw9r4p5prkj7lzfd1877wk11c9c73";
|
||||
};
|
||||
|
||||
|
|
|
@ -91,13 +91,13 @@ nix-build check.nix -A fetchurl --no-out-link --check
|
|||
nix-build check.nix -A fetchurl --no-out-link --repair
|
||||
[[ $(cat $path) != foo ]]
|
||||
|
||||
echo 'Hello World' > $TMPDIR/dummy
|
||||
echo 'Hello World' > $TEST_ROOT/dummy
|
||||
nix-build check.nix -A hashmismatch --no-out-link || status=$?
|
||||
[ "$status" = "102" ]
|
||||
|
||||
echo -n > $TMPDIR/dummy
|
||||
echo -n > $TEST_ROOT/dummy
|
||||
nix-build check.nix -A hashmismatch --no-out-link
|
||||
echo 'Hello World' > $TMPDIR/dummy
|
||||
echo 'Hello World' > $TEST_ROOT/dummy
|
||||
|
||||
nix-build check.nix -A hashmismatch --no-out-link --check || status=$?
|
||||
[ "$status" = "102" ]
|
||||
|
|
Loading…
Reference in a new issue