summaryrefslogtreecommitdiff
path: root/t/t5521-pull-options.sh
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2010-02-24 18:22:06 (GMT)
committerJunio C Hamano <gitster@pobox.com>2010-02-24 18:51:07 (GMT)
commitbba5322a71a3399a94f53e1dddf5bd66e493dfbc (patch)
treefa2a9a6d85494c785381d830119f600a7c3c68a6 /t/t5521-pull-options.sh
parent13e65fe6314bf44e64f22b9b66a4e5940adaa2e5 (diff)
downloadgit-bba5322a71a3399a94f53e1dddf5bd66e493dfbc.zip
git-bba5322a71a3399a94f53e1dddf5bd66e493dfbc.tar.gz
git-bba5322a71a3399a94f53e1dddf5bd66e493dfbc.tar.bz2
builtin-fetch --all/--multi: propagate options correctly
When running a subfetch, the code propagated some options but not others. Propagate --force, --update-head-ok and --keep options as well. Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't/t5521-pull-options.sh')
-rwxr-xr-xt/t5521-pull-options.sh21
1 files changed, 21 insertions, 0 deletions
diff --git a/t/t5521-pull-options.sh b/t/t5521-pull-options.sh
index c18d829..84059d8 100755
--- a/t/t5521-pull-options.sh
+++ b/t/t5521-pull-options.sh
@@ -51,4 +51,25 @@ test_expect_success 'git pull -q -v' '
test -s err)
'
+test_expect_success 'git pull --force' '
+ mkdir clonedoldstyle &&
+ (cd clonedoldstyle && git init &&
+ cat >>.git/config <<-\EOF &&
+ [remote "one"]
+ url = ../parent
+ fetch = refs/heads/master:refs/heads/mirror
+ [remote "two"]
+ url = ../parent
+ fetch = refs/heads/master:refs/heads/origin
+ [branch "master"]
+ remote = two
+ merge = refs/heads/master
+ EOF
+ git pull two &&
+ test_commit A &&
+ git branch -f origin &&
+ git pull --all --force
+ )
+'
+
test_done