Skip to content

Commit

Permalink
Fix referrers test
Browse files Browse the repository at this point in the history
This test broke the assumption that the hash parts of store paths are
unique.
  • Loading branch information
edolstra committed Oct 13, 2021
1 parent 1785ba2 commit e31a483
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions tests/referrers.sh
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,9 @@ echo "making registration..."

set +x
for ((n = 0; n < $max; n++)); do
storePath=$NIX_STORE_DIR/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa-$n
storePath=$NIX_STORE_DIR/$(printf "%05d\n" $n)aaaaaaaaaaaaaaaaaaaaaaaaaaa-$n
echo -n > $storePath
ref2=$NIX_STORE_DIR/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa-$((n+1))
ref2=$NIX_STORE_DIR/$(printf "%05d\n" $((n+1)))aaaaaaaaaaaaaaaaaaaaaaaaaaa-$((n+1))
if test $((n+1)) = $max; then
ref2=$reference
fi
Expand Down

0 comments on commit e31a483

Please sign in to comment.