git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
From: Junio C Hamano <gitster@pobox.com>
To: "Ævar Arnfjörð Bjarmason" <avarab@gmail.com>
Cc: Stefan Beller <sbeller@google.com>,
	"git\@vger.kernel.org" <git@vger.kernel.org>
Subject: Re: What's cooking in git.git (May 2017, #07; Tue, 23)
Date: Thu, 25 May 2017 12:42:12 +0900	[thread overview]
Message-ID: <xmqq60gpfvqj.fsf@gitster.mtv.corp.google.com> (raw)
In-Reply-To: <CACBZZX4adLy6Xumicu3Qke=g39EEe3iBa5ShsGvTBAYFqXENPg@mail.gmail.com> ("Ævar Arnfjörð Bjarmason"'s message of "Tue, 23 May 2017 21:50:37 +0200")

Ævar Arnfjörð Bjarmason <avarab@gmail.com> writes:

>> The tests added by grep rely on the old content of
>> test 2 'grep correctly finds patterns in a submodule'.
>
> Sorry about the fallout.
>
>> The (whitespace broken) diff below fixes it.

Ah, then, this was an example of maintainer not doing a good job.
When I see a topic that pass its own test that fails when merged to
'pu', I usually try to see where it goes wrong myself and come up
with a fix in an evil merge, but this time I didn't have enough time
to do so before sending out the "What's cooking" report.

Here is what I taught my merge-fix machinery to apply after
mechanical merge of the two topics.

 t/t7814-grep-recurse-submodules.sh | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/t/t7814-grep-recurse-submodules.sh b/t/t7814-grep-recurse-submodules.sh
index 14eeb54b4b..7184113b9b 100755
--- a/t/t7814-grep-recurse-submodules.sh
+++ b/t/t7814-grep-recurse-submodules.sh
@@ -36,18 +36,18 @@ test_expect_success 'grep correctly finds patterns in a submodule' '
 test_expect_success 'grep finds patterns in a submodule via config' '
 	test_config submodule.recurse true &&
 	# expect from previous test
-	git grep -e "bar" >actual &&
+	git grep -e "(3|4)" >actual &&
 	test_cmp expect actual
 '
 
 test_expect_success 'grep --no-recurse-submodules overrides config' '
 	test_config submodule.recurse true &&
 	cat >expect <<-\EOF &&
-	a:foobar
-	b/b:bar
+	a:(1|2)d(3|4)
+	b/b:(3|4)
 	EOF
 
-	git grep -e "bar" --no-recurse-submodules >actual &&
+	git grep -e "(3|4)" --no-recurse-submodules >actual &&
 	test_cmp expect actual
 '
 
-- 
2.13.0-491-g71cfeddc25


  reply	other threads:[~2017-05-25  3:42 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-05-23  8:08 What's cooking in git.git (May 2017, #07; Tue, 23) Junio C Hamano
2017-05-23 19:08 ` Stefan Beller
2017-05-23 19:38   ` Stefan Beller
2017-05-23 19:50     ` Ævar Arnfjörð Bjarmason
2017-05-25  3:42       ` Junio C Hamano [this message]
2017-05-25  5:42         ` Stefan Beller

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

  List information: http://vger.kernel.org/majordomo-info.html

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

  git send-email \
    --in-reply-to=xmqq60gpfvqj.fsf@gitster.mtv.corp.google.com \
    --to=gitster@pobox.com \
    --cc=avarab@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=sbeller@google.com \
    /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.
Code repositories for project(s) associated with this public inbox

	https://80x24.org/mirrors/git.git

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 read-only IMAP folder(s) and NNTP newsgroup(s).