@@ -7,16 +7,19 @@ TEST_PASSES_SANITIZE_LEAK=true
test_expect_success 'setup diverging branches' '
test_write_lines 1 2 3 4 5 6 7 8 9 10 >file &&
- git add file &&
+ cp file file2 &&
+ git add file file2 &&
git commit -m base &&
git tag base &&
sed s/2/two/ <file >tmp &&
mv tmp file &&
+ cp file file2 &&
git commit -a -m two &&
git tag two &&
git checkout -b other HEAD^ &&
sed s/10/ten/ <file >tmp &&
mv tmp file &&
+ cp file file2 &&
git commit -a -m ten &&
git tag ten
'
@@ -35,8 +38,11 @@ ten
EOF
test_expect_success 'read-tree does not resolve content merge' '
+ cat >expect <<-\EOF &&
+ file
+ file2
+ EOF
git read-tree -i -m base ten two &&
- echo file >expect &&
git diff-files --name-only --diff-filter=U >unmerged &&
test_cmp expect unmerged
'