X-Git-Url: https://git.tokkee.org/?a=blobdiff_plain;f=t%2Ft4202-log.sh;h=1dc224f6fbf074434728d326b8a36160e9032192;hb=d249515f297d47df6d79167b988eaa7db0981178;hp=779a5adf554d77464f2a326a2eb919e224993746;hpb=cb16bcc36965f28845e4fae15c36280a2506f1be;p=git.git diff --git a/t/t4202-log.sh b/t/t4202-log.sh index 779a5adf5..2230e606e 100755 --- a/t/t4202-log.sh +++ b/t/t4202-log.sh @@ -255,7 +255,7 @@ EOF test_expect_success 'log --graph with merge' ' git log --graph --date-order --pretty=tformat:%s | - sed "s/ *$//" >actual && + sed "s/ *\$//" >actual && test_cmp expect actual ' @@ -315,7 +315,7 @@ EOF test_expect_success 'log --graph with full output' ' git log --graph --date-order --pretty=short | git name-rev --name-only --stdin | - sed "s/Merge:.*/Merge: A B/;s/ *$//" >actual && + sed "s/Merge:.*/Merge: A B/;s/ *\$//" >actual && test_cmp expect actual ' @@ -383,9 +383,58 @@ EOF test_expect_success 'log --graph with merge' ' git log --graph --date-order --pretty=tformat:%s | - sed "s/ *$//" >actual && + sed "s/ *\$//" >actual && test_cmp expect actual ' +test_expect_success 'log.decorate configuration' ' + git config --unset-all log.decorate || : + + git log --oneline >expect.none && + git log --oneline --decorate >expect.short && + git log --oneline --decorate=full >expect.full && + + echo "[log] decorate" >>.git/config && + git log --oneline >actual && + test_cmp expect.short actual && + + git config --unset-all log.decorate && + git config log.decorate true && + git log --oneline >actual && + test_cmp expect.short actual && + git log --oneline --decorate=full >actual && + test_cmp expect.full actual && + git log --oneline --decorate=no >actual && + test_cmp expect.none actual && + + git config --unset-all log.decorate && + git config log.decorate no && + git log --oneline >actual && + test_cmp expect.none actual && + git log --oneline --decorate >actual && + test_cmp expect.short actual && + git log --oneline --decorate=full >actual && + test_cmp expect.full actual && + + git config --unset-all log.decorate && + git config log.decorate short && + git log --oneline >actual && + test_cmp expect.short actual && + git log --oneline --no-decorate >actual && + test_cmp expect.none actual && + git log --oneline --decorate=full >actual && + test_cmp expect.full actual && + + git config --unset-all log.decorate && + git config log.decorate full && + git log --oneline >actual && + test_cmp expect.full actual && + git log --oneline --no-decorate >actual && + test_cmp expect.none actual && + git log --oneline --decorate >actual && + test_cmp expect.short actual + +' + test_done