test_expect_success \
'prepare reference tree' \
'mkdir path0 path1 &&
- cp ../../COPYING path0/COPYING &&
+ cp "$TEST_DIRECTORY"/../COPYING path0/COPYING &&
git add path0/COPYING &&
git-commit -m add -a'
test_expect_success \
'adding another file' \
- 'cp ../../README path0/README &&
+ 'cp "$TEST_DIRECTORY"/../README path0/README &&
git add path0/README &&
git-commit -m add2 -a'
! test -e moved &&
test -f symlink &&
test "$(cat symlink)" = 1 &&
+ git update-index --refresh &&
git diff-files --quiet
'
git mv -f symlink moved &&
! test -e symlink &&
test -h moved &&
+ git update-index --refresh &&
git diff-files --quiet
'