git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jeff King <peff@peff.net>
To: git@vger.kernel.org
Subject: [PATCH 1/3] t6031: move triple-rename test to t3030
Date: Mon, 26 Oct 2015 17:36:18 -0400	[thread overview]
Message-ID: <20151026213618.GA17373@sigill.intra.peff.net> (raw)
In-Reply-To: <20151026213502.GA17244@sigill.intra.peff.net>

The t6031 test was introduced to check filemode handling of
merge-recursive. Much later, an unrelated test was tacked on
to look at renames and d/f conflicts. This test does not
depend on anything that happened before (it actually blows
away any existing content in the test repo). Let's move it
to t3030, where there are more related tests.

Signed-off-by: Jeff King <peff@peff.net>
---
I didn't actually look all that closely at what it does and what t3030
does to see if there is overlap, and we could simply get rid of this.
But it _definitely_ doesn't belong in t6031, so this is at least a step
forward.

 t/t3030-merge-recursive.sh | 30 ++++++++++++++++++++++++++++++
 t/t6031-merge-recursive.sh | 31 -------------------------------
 2 files changed, 30 insertions(+), 31 deletions(-)

diff --git a/t/t3030-merge-recursive.sh b/t/t3030-merge-recursive.sh
index 82e1854..6224187 100755
--- a/t/t3030-merge-recursive.sh
+++ b/t/t3030-merge-recursive.sh
@@ -629,5 +629,35 @@ test_expect_failure 'merge-recursive rename vs. rename/symlink' '
 	test_cmp expected actual
 '
 
+test_expect_success 'merging with triple rename across D/F conflict' '
+	git reset --hard HEAD &&
+	git checkout -b main &&
+	git rm -rf . &&
+
+	echo "just a file" >sub1 &&
+	mkdir -p sub2 &&
+	echo content1 >sub2/file1 &&
+	echo content2 >sub2/file2 &&
+	echo content3 >sub2/file3 &&
+	mkdir simple &&
+	echo base >simple/bar &&
+	git add -A &&
+	test_tick &&
+	git commit -m base &&
+
+	git checkout -b other &&
+	echo more >>simple/bar &&
+	test_tick &&
+	git commit -a -m changesimplefile &&
+
+	git checkout main &&
+	git rm sub1 &&
+	git mv sub2 sub1 &&
+	test_tick &&
+	git commit -m changefiletodir &&
+
+	test_tick &&
+	git merge other
+'
 
 test_done
diff --git a/t/t6031-merge-recursive.sh b/t/t6031-merge-recursive.sh
index 6464a16..4053bd9 100755
--- a/t/t6031-merge-recursive.sh
+++ b/t/t6031-merge-recursive.sh
@@ -53,35 +53,4 @@ test_expect_success FILEMODE 'verify executable bit on file' '
 	test -x file2
 '
 
-test_expect_success 'merging with triple rename across D/F conflict' '
-	git reset --hard HEAD &&
-	git checkout -b main &&
-	git rm -rf . &&
-
-	echo "just a file" >sub1 &&
-	mkdir -p sub2 &&
-	echo content1 >sub2/file1 &&
-	echo content2 >sub2/file2 &&
-	echo content3 >sub2/file3 &&
-	mkdir simple &&
-	echo base >simple/bar &&
-	git add -A &&
-	test_tick &&
-	git commit -m base &&
-
-	git checkout -b other &&
-	echo more >>simple/bar &&
-	test_tick &&
-	git commit -a -m changesimplefile &&
-
-	git checkout main &&
-	git rm sub1 &&
-	git mv sub2 sub1 &&
-	test_tick &&
-	git commit -m changefiletodir &&
-
-	test_tick &&
-	git merge other
-'
-
 test_done
-- 
2.6.2.481.g6ca35c3

  reply	other threads:[~2015-10-26 21:36 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-10-26 21:35 [PATCH 0/3] detecting delete/modechange conflicts Jeff King
2015-10-26 21:36 ` Jeff King [this message]
2015-10-26 21:37 ` [PATCH 2/3] t6031: generalize for recursive and resolve strategies Jeff King
2015-10-26 21:39 ` [PATCH 3/3] merge: detect delete/modechange conflict Jeff King
2015-10-26 21:46 ` [PATCH 0/3] detecting delete/modechange conflicts Junio C Hamano
2015-10-26 21:54   ` Jeff King

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20151026213618.GA17373@sigill.intra.peff.net \
    --to=peff@peff.net \
    --cc=git@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).