summaryrefslogtreecommitdiff
path: root/Documentation/git-gc.txt
diff options
context:
space:
mode:
authorElijah Newren <newren@gmail.com>2019-09-04 22:32:37 (GMT)
committerJunio C Hamano <gitster@pobox.com>2019-09-05 20:01:48 (GMT)
commit7b6ad979391d908698cdef9358d3e13979e15c9f (patch)
tree5a26f27f25f5cf4f4444d06426e41175cfa8e45b /Documentation/git-gc.txt
parent745f6812895b31c02b29bdfe4ae8e5498f776c26 (diff)
downloadgit-7b6ad979391d908698cdef9358d3e13979e15c9f.zip
git-7b6ad979391d908698cdef9358d3e13979e15c9f.tar.gz
git-7b6ad979391d908698cdef9358d3e13979e15c9f.tar.bz2
t6006: simplify, fix, and optimize empty message test
Test t6006.71 ("oneline with empty message") was creating two commits with simple commit messages, and then running filter-branch to rewrite the commit messages to be "empty". This test was introduced in commit 1fb5fdd25f0 ("rev-list: fix --pretty=oneline with empty message", 2010-03-21) and written this way because the --allow-empty-message option to git commit did not exist at the time. However, the filter-branch invocation used differed slightly from --allow-empty-message in that it would have a commit message consisting solely of a single newline, and as such was not testing what the original commit intended to test. Since both a truly empty commit message and a commit message with a single linefeed could trigger the original bug, modify the test slightly to include an example of each. Despite only being one piece of the 71st test and there being 73 tests overall, this small change to just this one test speeds up the overall execution time of t6006 (as measured by the best of 3 runs of `time ./t6006-rev-list-format.sh`) by about 11% on Linux, 13% on Mac, and about 15% on Windows. Signed-off-by: Elijah Newren <newren@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'Documentation/git-gc.txt')
0 files changed, 0 insertions, 0 deletions