summaryrefslogtreecommitdiff
path: root/t/t2020-checkout-detach.sh
diff options
context:
space:
mode:
authorÆvar Arnfjörð Bjarmason <avarab@gmail.com>2011-04-10 19:34:08 (GMT)
committerJunio C Hamano <gitster@pobox.com>2011-04-12 07:20:28 (GMT)
commitf06f08b78c1c8be7039bd94c5f1fb305812fda34 (patch)
tree10c9951d72886e3e6c425b53045b8a8aadcdcd95 /t/t2020-checkout-detach.sh
parent20fc73e3b0bb2b115d88e54514db13ffaf11b025 (diff)
downloadgit-f06f08b78c1c8be7039bd94c5f1fb305812fda34.zip
git-f06f08b78c1c8be7039bd94c5f1fb305812fda34.tar.gz
git-f06f08b78c1c8be7039bd94c5f1fb305812fda34.tar.bz2
i18n: mark checkout plural warning for translation
Mark the "Warning: you are leaving %d commit(s) behind" message added in v1.7.5-rc0~74^2 (commit: give final warning when reattaching HEAD to leave commits behind) by Junio C Hamano for translation. This message requires the use of ngettext() features, and is the first message to use the Q_() wrapper around ngettext(). Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't/t2020-checkout-detach.sh')
-rwxr-xr-xt/t2020-checkout-detach.sh15
1 files changed, 12 insertions, 3 deletions
diff --git a/t/t2020-checkout-detach.sh b/t/t2020-checkout-detach.sh
index 569b27f..ab782e2 100755
--- a/t/t2020-checkout-detach.sh
+++ b/t/t2020-checkout-detach.sh
@@ -108,21 +108,30 @@ test_expect_success 'checkout warns on orphan commits' '
echo content >orphan &&
git add orphan &&
git commit -a -m orphan &&
- git checkout master 2>stderr &&
+ git checkout master 2>stderr
+'
+
+test_expect_success C_LOCALE_OUTPUT 'checkout warns on orphan commits: output' '
check_orphan_warning stderr
'
test_expect_success 'checkout does not warn leaving ref tip' '
reset &&
git checkout --detach two &&
- git checkout master 2>stderr &&
+ git checkout master 2>stderr
+'
+
+test_expect_success C_LOCALE_OUTPUT 'checkout does not warn leaving ref tip' '
check_no_orphan_warning stderr
'
test_expect_success 'checkout does not warn leaving reachable commit' '
reset &&
git checkout --detach HEAD^ &&
- git checkout master 2>stderr &&
+ git checkout master 2>stderr
+'
+
+test_expect_success C_LOCALE_OUTPUT 'checkout does not warn leaving reachable commit' '
check_no_orphan_warning stderr
'