aboutsummaryrefslogtreecommitdiff
path: root/t
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2008-08-24 14:48:36 -0700
committerJunio C Hamano <gitster@pobox.com>2008-08-24 14:50:44 -0700
commit49d3536594e653717844d53825fa7c0a494888f7 (patch)
tree35022ab151934461b2a9f21cce140b5a773369c6 /t
parent98fcf840af443a0a93b9a6cd1fada5af826383f3 (diff)
parent5760a6b094736e6f59eb32c7abb4cdbb7fca1627 (diff)
downloadgit-49d3536594e653717844d53825fa7c0a494888f7.tar.gz
git-49d3536594e653717844d53825fa7c0a494888f7.tar.xz
Merge branch 'maint' to sync with 1.6.0.1
Diffstat (limited to 't')
-rwxr-xr-xt/t3030-merge-recursive.sh11
-rwxr-xr-xt/t4015-diff-whitespace.sh16
-rwxr-xr-xt/t7600-merge.sh9
-rwxr-xr-xt/t7605-merge-resolve.sh4
4 files changed, 39 insertions, 1 deletions
diff --git a/t/t3030-merge-recursive.sh b/t/t3030-merge-recursive.sh
index aff360303..f2880152b 100755
--- a/t/t3030-merge-recursive.sh
+++ b/t/t3030-merge-recursive.sh
@@ -269,6 +269,17 @@ test_expect_success 'merge-recursive result' '
'
+test_expect_success 'fail if the index has unresolved entries' '
+
+ rm -fr [abcd] &&
+ git checkout -f "$c1" &&
+
+ test_must_fail git merge "$c5" &&
+ test_must_fail git merge "$c5" 2> out &&
+ grep "You are in the middle of a conflicted merge" out
+
+'
+
test_expect_success 'merge-recursive remove conflict' '
rm -fr [abcd] &&
diff --git a/t/t4015-diff-whitespace.sh b/t/t4015-diff-whitespace.sh
index f9eb67d83..fc2307eaa 100755
--- a/t/t4015-diff-whitespace.sh
+++ b/t/t4015-diff-whitespace.sh
@@ -352,4 +352,20 @@ test_expect_success 'checkdiff allows new blank lines' '
git diff --check
'
+test_expect_success 'combined diff with autocrlf conversion' '
+
+ git reset --hard &&
+ echo >x hello &&
+ git commit -m "one side" x &&
+ git checkout HEAD^ &&
+ echo >x goodbye &&
+ git commit -m "the other side" x &&
+ git config core.autocrlf true &&
+ test_must_fail git merge master &&
+
+ git diff | sed -e "1,/^@@@/d" >actual &&
+ ! grep "^-" actual
+
+'
+
test_done
diff --git a/t/t7600-merge.sh b/t/t7600-merge.sh
index fee8fb77d..dbc90bc41 100755
--- a/t/t7600-merge.sh
+++ b/t/t7600-merge.sh
@@ -498,4 +498,13 @@ test_expect_success 'merge fast-forward in a dirty tree' '
test_debug 'gitk --all'
+test_expect_success 'in-index merge' '
+ git reset --hard c0 &&
+ git merge --no-ff -s resolve c1 > out &&
+ grep "Wonderful." out &&
+ verify_parents $c0 $c1
+'
+
+test_debug 'gitk --all'
+
test_done
diff --git a/t/t7605-merge-resolve.sh b/t/t7605-merge-resolve.sh
index ee21a107f..f1f86ddb2 100755
--- a/t/t7605-merge-resolve.sh
+++ b/t/t7605-merge-resolve.sh
@@ -36,7 +36,9 @@ test_expect_success 'merge c1 to c2' '
git diff --exit-code &&
test -f c0.c &&
test -f c1.c &&
- test -f c2.c
+ test -f c2.c &&
+ test 3 = $(git ls-tree -r HEAD | wc -l) &&
+ test 3 = $(git ls-files | wc -l)
'
test_expect_success 'merge c2 to c3 (fails)' '