X-Git-Url: https://git.tokkee.org/?a=blobdiff_plain;f=t%2Ft4026-color.sh;h=5ade44c043ca6577b2e331b152515359128dbd32;hb=a1bb8f45f1590f812badceea0b7c120074ec3e85;hp=b61e5169f4e9e8d9f87b9ea16e71dfcf1fb9f340;hpb=392f1300911120fbaa4b77c737fe13e205726aca;p=git.git diff --git a/t/t4026-color.sh b/t/t4026-color.sh index b61e5169f..5ade44c04 100755 --- a/t/t4026-color.sh +++ b/t/t4026-color.sh @@ -66,4 +66,21 @@ test_expect_success 'extra character after attribute' ' invalid_color "dimX" ' +test_expect_success 'unknown color slots are ignored (diff)' ' + git config --unset diff.color.new + git config color.diff.nosuchslotwilleverbedefined white && + git diff --color +' + +test_expect_success 'unknown color slots are ignored (branch)' ' + git config color.branch.nosuchslotwilleverbedefined white && + git branch -a +' + +test_expect_success 'unknown color slots are ignored (status)' ' + git config color.status.nosuchslotwilleverbedefined white || exit + git status + case $? in 0|1) : ok ;; *) false ;; esac +' + test_done