log: test --decorate-refs-exclude with --simplify-by-decoration

Demonstrate that a decoration filter given with --decorate-refs-exclude is inadvertently overruled by --simplify-by-decoration. Reported-by: Étienne SERVAIS <etienne.servais@voucoux.fr> Signed-off-by: René Scharfe <l.s.r@web.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>

René Scharfe committed Sep 8, 2019 at 19:58 UTC b4ecbcf6a256e533a3e0231095758527999e7fe0
1 file changed +15
t/t4202-log.sh
+15
@@ -837,6 +837,21 @@ test_expect_success 'decorate-refs and decorate-refs-exclude' '
837 test_cmp expect.decorate actual
838 '
839
840 +test_expect_failure 'decorate-refs-exclude and simplify-by-decoration' '
841 + cat >expect.decorate <<-\EOF &&
842 + Merge-tag-reach (HEAD -> master)
843 + reach (tag: reach, reach)
844 + seventh (tag: seventh)
845 + Merge-branch-tangle
846 + Merge-branch-side-early-part-into-tangle (tangle)
847 + tangle-a (tag: tangle-a)
848 + EOF
849 + git log -n6 --decorate=short --pretty="tformat:%f%d" \
850 + --decorate-refs-exclude="*octopus*" \
851 + --simplify-by-decoration >actual &&
852 + test_cmp expect.decorate actual
853 +'
854 +
855 test_expect_success 'log.decorate config parsing' '
856 git log --oneline --decorate=full >expect.full &&
857 git log --oneline --decorate=short >expect.short &&