test_description='merging when a directory was replaced with a symlink'
. ./test-lib.sh
+if ! test_have_prereq SYMLINKS
+then
+ skip_all='Symbolic links not supported, skipping tests.'
+ test_done
+fi
+
test_expect_success 'create a commit where dir a/b changed to symlink' '
mkdir -p a/b/c a/b-2/c &&
> a/b/c/d &&
git commit -m "dir to symlink"
'
-test_expect_failure 'keep a/b-2/c/d across checkout' '
+test_expect_success 'keep a/b-2/c/d across checkout' '
git checkout HEAD^0 &&
git reset --hard master &&
git rm --cached a/b &&
git tag test2
'
-test_expect_failure 'merge should not have conflicts (resolve)' '
+test_expect_success 'merge should not have conflicts (resolve)' '
git reset --hard &&
git checkout baseline^0 &&
git merge -s resolve test2 &&