summaryrefslogtreecommitdiff
path: root/t
diff options
context:
space:
mode:
authorLibravatar Eduardo R. D'Avila <erdavila@gmail.com>2013-06-26 00:05:16 -0300
committerLibravatar Junio C Hamano <gitster@pobox.com>2013-06-26 13:03:01 -0700
commit15981f4eec9c6a7c12b9c0fbe98e68228c46edb7 (patch)
treea7e6f5b7c00a5451059533656a057cfe92f18034 /t
parentt9903: remove redundant tests (diff)
downloadtgif-15981f4eec9c6a7c12b9c0fbe98e68228c46edb7.tar.xz
git-prompt.sh: do not print duplicate clean color code
Do not print a duplicate clean color code when there is no other indicators other than the current branch in colored prompt. Acked-by: SZEDER Gábor <szeder@ira.uka.de> Signed-off-by: Eduardo R. D'Avila <erdavila@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't')
-rwxr-xr-xt/t9903-bash-prompt.sh8
1 files changed, 4 insertions, 4 deletions
diff --git a/t/t9903-bash-prompt.sh b/t/t9903-bash-prompt.sh
index f250dfc55a..5cd138ed9a 100755
--- a/t/t9903-bash-prompt.sh
+++ b/t/t9903-bash-prompt.sh
@@ -551,7 +551,7 @@ test_expect_success 'prompt - pc mode' '
'
test_expect_success 'prompt - bash color pc mode - branch name' '
- printf "BEFORE: (${c_green}master${c_clear}${c_clear}):AFTER" >expected &&
+ printf "BEFORE: (${c_green}master${c_clear}):AFTER" >expected &&
(
GIT_PS1_SHOWCOLORHINTS=y &&
__git_ps1 "BEFORE:" ":AFTER" >"$actual"
@@ -561,7 +561,7 @@ test_expect_success 'prompt - bash color pc mode - branch name' '
'
test_expect_success 'prompt - bash color pc mode - detached head' '
- printf "BEFORE: (${c_red}(%s...)${c_clear}${c_clear}):AFTER" $(git log -1 --format="%h" b1^) >expected &&
+ printf "BEFORE: (${c_red}(%s...)${c_clear}):AFTER" $(git log -1 --format="%h" b1^) >expected &&
git checkout b1^ &&
test_when_finished "git checkout master" &&
(
@@ -627,7 +627,7 @@ test_expect_success 'prompt - bash color pc mode - dirty status indicator - befo
'
test_expect_success 'prompt - bash color pc mode - inside .git directory' '
- printf "BEFORE: (${c_green}GIT_DIR!${c_clear}${c_clear}):AFTER" >expected &&
+ printf "BEFORE: (${c_green}GIT_DIR!${c_clear}):AFTER" >expected &&
echo "dirty" >file &&
test_when_finished "git reset --hard" &&
(
@@ -666,7 +666,7 @@ test_expect_success 'prompt - bash color pc mode - untracked files status indica
'
test_expect_success 'prompt - zsh color pc mode' '
- printf "BEFORE: (%%F{green}master%%f%%f):AFTER" >expected &&
+ printf "BEFORE: (%%F{green}master%%f):AFTER" >expected &&
(
ZSH_VERSION=5.0.0 &&
GIT_PS1_SHOWCOLORHINTS=y &&