X-Git-Url: https://asedeno.scripts.mit.edu/gitweb/?a=blobdiff_plain;f=t%2Ft4026-color.sh;h=5ade44c043ca6577b2e331b152515359128dbd32;hb=f3604763ba0355f628cf815cfaf4fec20d46e958;hp=b61e5169f4e9e8d9f87b9ea16e71dfcf1fb9f340;hpb=547905f8cd2a04b3e1117f00025b60f81aa60f47;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