diff options
Diffstat (limited to 't/t4205-log-pretty-formats.sh')
-rwxr-xr-x | t/t4205-log-pretty-formats.sh | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/t/t4205-log-pretty-formats.sh b/t/t4205-log-pretty-formats.sh index 349c531989..7398605e7b 100755 --- a/t/t4205-log-pretty-formats.sh +++ b/t/t4205-log-pretty-formats.sh @@ -431,6 +431,21 @@ EOF test_cmp expected actual ' +test_expect_success 'strbuf_utf8_replace() not producing NUL' ' + git log --color --pretty="tformat:%<(10,trunc)%s%>>(10,ltrunc)%C(auto)%d" | + test_decode_color | + nul_to_q >actual && + ! grep Q actual +' + +# ISO strict date format +test_expect_success 'ISO and ISO-strict date formats display the same values' ' + git log --format=%ai%n%ci | + sed -e "s/ /T/; s/ //; s/..\$/:&/" >expected && + git log --format=%aI%n%cI >actual && + test_cmp expected actual +' + # get new digests (with no abbreviations) head1=$(git rev-parse --verify HEAD~0) && head2=$(git rev-parse --verify HEAD~1) && @@ -450,4 +465,15 @@ EOF test_cmp expected actual1 ' +test_expect_success 'clean log decoration' ' + git log --no-walk --tags --pretty="%H %D" --decorate=full >actual && + cat >expected <<EOF && +$head1 tag: refs/tags/tag2 +$head2 tag: refs/tags/message-one +$old_head1 tag: refs/tags/message-two +EOF + sort actual >actual1 && + test_cmp expected actual1 +' + test_done |