summaryrefslogtreecommitdiffstats
path: root/t
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2012-09-11 20:10:17 +0200
committerJunio C Hamano <gitster@pobox.com>2012-09-11 20:10:17 +0200
commitee7a83f6314a6fe281c8e3e041cfd42b5a2deb44 (patch)
tree2dfda34bb7872b99c9af10b66201b596663b5370 /t
parentMerge branch 'ph/stash-rerere' into maint-1.7.11 (diff)
parentMake 'git submodule update --force' always check out submodules. (diff)
downloadgit-ee7a83f6314a6fe281c8e3e041cfd42b5a2deb44.tar.xz
git-ee7a83f6314a6fe281c8e3e041cfd42b5a2deb44.zip
Merge branch 'sz/submodule-force-update' into maint-1.7.11
* sz/submodule-force-update: Make 'git submodule update --force' always check out submodules.
Diffstat (limited to 't')
-rwxr-xr-xt/t7406-submodule-update.sh12
1 files changed, 12 insertions, 0 deletions
diff --git a/t/t7406-submodule-update.sh b/t/t7406-submodule-update.sh
index 646298b212..15426530e4 100755
--- a/t/t7406-submodule-update.sh
+++ b/t/t7406-submodule-update.sh
@@ -123,6 +123,18 @@ test_expect_success 'submodule update should throw away changes with --force ' '
)
'
+test_expect_success 'submodule update --force forcibly checks out submodules' '
+ (cd super &&
+ (cd submodule &&
+ rm -f file
+ ) &&
+ git submodule update --force submodule &&
+ (cd submodule &&
+ test "$(git status -s file)" = ""
+ )
+ )
+'
+
test_expect_success 'submodule update --rebase staying on master' '
(cd super/submodule &&
git checkout master