From: Barret Rhoden <brho@google.com>
To: Derrick Stolee <stolee@gmail.com>,
GIT Mailing-list <git@vger.kernel.org>
Cc: michael@platin.gs, Jonathan Tan <jonathantanmy@google.com>
Subject: Re: Git Test Coverage Report (Thursday, May 30th)
Date: Tue, 4 Jun 2019 16:41:33 -0400 [thread overview]
Message-ID: <09bc8c7a-bab5-7cdb-75dc-f7c45a4dbaf8@google.com> (raw)
In-Reply-To: <9ab619bb-9deb-4e57-a3ad-9e996425b783@google.com>
Hi -
On 6/4/19 12:38 PM, Barret Rhoden wrote:
> I'll try to come up with a test, independent of my blame-ignore work,
> that can get in that block.
I have a test that covers blame_coalesce(), which works both with and
without my blame-ignore commit that started this thread.
However, the only thing we are really testing is that git blame didn't
crash. There is no detectable change to the output. AFAIK,
blame_coalesce() is a performance enhancement.
If you all are interested in that sort of test, I can put it in a patch.
Right now, I have this (below).
Thanks,
Barret
diff --git a/t/t8003-blame-corner-cases.sh b/t/t8003-blame-corner-cases.sh
index c92a47b6d5b1..4c652b85a55b 100755
--- a/t/t8003-blame-corner-cases.sh
+++ b/t/t8003-blame-corner-cases.sh
@@ -275,4 +275,32 @@ test_expect_success 'blame file with CRLF
core.autocrlf=true' '
grep "A U Thor" actual
'
+test_expect_success 'blame coalesce' '
+ cat >giraffe <<-\EOF &&
+ ABC
+ DEF
+ EOF
+ git add giraffe &&
+ git commit -m "original file" &&
+
+ cat >giraffe <<-\EOF &&
+ ABC
+ XXX
+ DEF
+ EOF
+ git add giraffe &&
+ git commit -m "interior XXX line" &&
+
+ cat >giraffe <<-\EOF &&
+ ABC
+ DEF
+ EOF
+ git add giraffe &&
+ git commit -m "same contents as original" &&
+
+ git blame giraffe &&
+
+ true
+'
+
test_done
next prev parent reply other threads:[~2019-06-04 20:41 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-05-30 12:52 Git Test Coverage Report (Thursday, May 30th) Derrick Stolee
2019-05-30 18:24 ` Derrick Stolee
2019-05-31 17:51 ` Derrick Stolee
2019-05-31 18:59 ` Johannes Schindelin
2019-06-01 21:22 ` Michael Platings
2019-06-03 18:11 ` Barret Rhoden
2019-06-03 18:40 ` Derrick Stolee
2019-06-04 16:38 ` Barret Rhoden
2019-06-04 20:41 ` Barret Rhoden [this message]
2019-06-05 0:57 ` Derrick Stolee
2019-06-10 15:15 ` Barret Rhoden
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=09bc8c7a-bab5-7cdb-75dc-f7c45a4dbaf8@google.com \
--to=brho@google.com \
--cc=git@vger.kernel.org \
--cc=jonathantanmy@google.com \
--cc=michael@platin.gs \
--cc=stolee@gmail.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).