From 3604e7c5c6f8d48e221ea5b21ef26fc3e27eff9e Mon Sep 17 00:00:00 2001 From: Nanako Shiraishi Date: Wed, 3 Sep 2008 17:59:29 +0900 Subject: tests: use "git xyzzy" form (t3600 - t6999) Converts tests between t3600-t6300. Signed-off-by: Nanako Shiraishi Signed-off-by: Junio C Hamano --- t/t6026-merge-attr.sh | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 't/t6026-merge-attr.sh') diff --git a/t/t6026-merge-attr.sh b/t/t6026-merge-attr.sh index 56fc341768..4b423e937d 100755 --- a/t/t6026-merge-attr.sh +++ b/t/t6026-merge-attr.sh @@ -106,9 +106,9 @@ test_expect_success 'custom merge backend' ' cmp binary union && sed -e 1,3d text >check-1 && - o=$(git-unpack-file master^:text) && - a=$(git-unpack-file side^:text) && - b=$(git-unpack-file master:text) && + o=$(git unpack-file master^:text) && + a=$(git unpack-file side^:text) && + b=$(git unpack-file master:text) && sh -c "./custom-merge $o $a $b 0" && sed -e 1,3d $a >check-2 && cmp check-1 check-2 && @@ -133,9 +133,9 @@ test_expect_success 'custom merge backend' ' cmp binary union && sed -e 1,3d text >check-1 && - o=$(git-unpack-file master^:text) && - a=$(git-unpack-file anchor:text) && - b=$(git-unpack-file master:text) && + o=$(git unpack-file master^:text) && + a=$(git unpack-file anchor:text) && + b=$(git unpack-file master:text) && sh -c "./custom-merge $o $a $b 0" && sed -e 1,3d $a >check-2 && cmp check-1 check-2 && -- cgit v1.2.3 From 4271666046b4b3e655eab88821096539099f3b14 Mon Sep 17 00:00:00 2001 From: Miklos Vajna Date: Sat, 6 Sep 2008 18:29:49 +0200 Subject: builtin-merge: release the lockfile in try_merge_strategy() Once we committed the locked index, we should release the lockfile. In most cases this is done automatically when the process ends, but this is not true in this case. [jc: with additional tests from Eric Raible] Signed-off-by: Miklos Vajna Signed-off-by: Junio C Hamano --- t/t6026-merge-attr.sh | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) (limited to 't/t6026-merge-attr.sh') diff --git a/t/t6026-merge-attr.sh b/t/t6026-merge-attr.sh index 56fc341768..86f47ca595 100755 --- a/t/t6026-merge-attr.sh +++ b/t/t6026-merge-attr.sh @@ -142,4 +142,26 @@ test_expect_success 'custom merge backend' ' rm -f $o $a $b ' +test_expect_success 'up-to-date merge without common ancestor' ' + test_create_repo repo1 && + test_create_repo repo2 && + test_tick && + ( + cd repo1 && + >a && + git add a && + git commit -m initial + ) && + test_tick && + ( + cd repo2 && + git commit --allow-empty -m initial + ) && + test_tick && + ( + cd repo1 && + git pull ../repo2 master + ) +' + test_done -- cgit v1.2.3