X-Git-Url: https://git.tokkee.org/?a=blobdiff_plain;f=t%2Ft4026-color.sh;h=5ade44c043ca6577b2e331b152515359128dbd32;hb=0b4ae29f0328fb8c270030abad132e8f50e05381;hp=b61e5169f4e9e8d9f87b9ea16e71dfcf1fb9f340;hpb=77ad7a49d3cc946487ca759e5361effbcfb03be5;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