aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNanako Shiraishi <nanako3@lavabit.com>2009-05-17 11:43:08 +0900
committerJunio C Hamano <gitster@pobox.com>2009-05-16 19:49:25 -0700
commite4b09dad9f65395fd4bb8ab165012a3a6698a75b (patch)
treeb1be4be8236768e952f47773f3719f6df0d9402e
parentdd42c2f015102626562da05bb290f47862ea06fb (diff)
downloadgit-e4b09dad9f65395fd4bb8ab165012a3a6698a75b.tar.gz
git-e4b09dad9f65395fd4bb8ab165012a3a6698a75b.tar.xz
test: checkout shouldn't say that HEAD has moved if it didn't
Signed-off-by: しらいしななこ <nanako3@lavabit.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
-rwxr-xr-xt/t7201-co.sh8
1 files changed, 8 insertions, 0 deletions
diff --git a/t/t7201-co.sh b/t/t7201-co.sh
index bdb808af1..ebfd34df3 100755
--- a/t/t7201-co.sh
+++ b/t/t7201-co.sh
@@ -534,4 +534,12 @@ test_expect_success 'failing checkout -b should not break working tree' '
'
+test_expect_success 'switch out of non-branch' '
+ git reset --hard master &&
+ git checkout master^0 &&
+ echo modified >one &&
+ test_must_fail git checkout renamer 2>error.log &&
+ ! grep "^Previous HEAD" error.log
+'
+
test_done