mirror of
https://github.com/privatevoid-net/nix-super.git
synced 2024-11-22 05:56:15 +02:00
Handle $TMPDIR ending with a slash
This caused the gc test to fail on Darwin.
This commit is contained in:
parent
29727ff944
commit
af3db853fa
2 changed files with 2 additions and 2 deletions
|
@ -2,7 +2,7 @@ set -e
|
||||||
|
|
||||||
datadir="@datadir@"
|
datadir="@datadir@"
|
||||||
|
|
||||||
export TEST_ROOT=${TMPDIR:-/tmp}/nix-test
|
export TEST_ROOT=$(realpath ${TMPDIR:-/tmp}/nix-test)
|
||||||
export NIX_STORE_DIR
|
export NIX_STORE_DIR
|
||||||
if ! NIX_STORE_DIR=$(readlink -f $TEST_ROOT/store 2> /dev/null); then
|
if ! NIX_STORE_DIR=$(readlink -f $TEST_ROOT/store 2> /dev/null); then
|
||||||
# Maybe the build directory is symlinked.
|
# Maybe the build directory is symlinked.
|
||||||
|
|
|
@ -18,7 +18,7 @@ if test "$text" != "Hello World!"; then exit 1; fi
|
||||||
nix-store --delete $outPath
|
nix-store --delete $outPath
|
||||||
if test -e $outPath/hello; then false; fi
|
if test -e $outPath/hello; then false; fi
|
||||||
|
|
||||||
outPath="$(NIX_REMOTE=local?store=/foo\&real=$TMPDIR/real-store nix-instantiate --readonly-mode hash-check.nix)"
|
outPath="$(NIX_REMOTE=local?store=/foo\&real=$TEST_ROOT/real-store nix-instantiate --readonly-mode hash-check.nix)"
|
||||||
if test "$outPath" != "/foo/lfy1s6ca46rm5r6w4gg9hc0axiakjcnm-dependencies.drv"; then
|
if test "$outPath" != "/foo/lfy1s6ca46rm5r6w4gg9hc0axiakjcnm-dependencies.drv"; then
|
||||||
echo "hashDerivationModulo appears broken, got $outPath"
|
echo "hashDerivationModulo appears broken, got $outPath"
|
||||||
exit 1
|
exit 1
|
||||||
|
|
Loading…
Reference in a new issue