diff options
Diffstat (limited to 't/t7600-merge.sh')
-rwxr-xr-x | t/t7600-merge.sh | 42 |
1 files changed, 41 insertions, 1 deletions
diff --git a/t/t7600-merge.sh b/t/t7600-merge.sh index daf45b7ff..5eeb6c2b2 100755 --- a/t/t7600-merge.sh +++ b/t/t7600-merge.sh @@ -126,7 +126,7 @@ verify_merge() { echo "[OOPS] unmerged files" false fi && - if ! git diff --exit-code + if test_must_fail git diff --exit-code then echo "[OOPS] working tree != index" false @@ -441,11 +441,51 @@ test_expect_success 'merge log message' ' git merge --no-log c2 && git show -s --pretty=format:%b HEAD >msg.act && verify_diff msg.nolog msg.act "[OOPS] bad merge log message" && + git merge --log c3 && git show -s --pretty=format:%b HEAD >msg.act && + verify_diff msg.log msg.act "[OOPS] bad merge log message" && + + git reset --hard HEAD^ && + git config merge.log yes && + git merge c3 && + git show -s --pretty=format:%b HEAD >msg.act && verify_diff msg.log msg.act "[OOPS] bad merge log message" ' test_debug 'gitk --all' +test_expect_success 'merge c1 with c0, c2, c0, and c1' ' + git reset --hard c1 && + git config branch.master.mergeoptions "" && + test_tick && + git merge c0 c2 c0 c1 && + verify_merge file result.1-5 && + verify_parents $c1 $c2 +' + +test_debug 'gitk --all' + +test_expect_success 'merge c1 with c0, c2, c0, and c1' ' + git reset --hard c1 && + git config branch.master.mergeoptions "" && + test_tick && + git merge c0 c2 c0 c1 && + verify_merge file result.1-5 && + verify_parents $c1 $c2 +' + +test_debug 'gitk --all' + +test_expect_success 'merge c1 with c1 and c2' ' + git reset --hard c1 && + git config branch.master.mergeoptions "" && + test_tick && + git merge c1 c2 && + verify_merge file result.1-5 && + verify_parents $c1 $c2 +' + +test_debug 'gitk --all' + test_done |