summaryrefslogtreecommitdiff
path: root/t/t7403-submodule-sync.sh
diff options
context:
space:
mode:
authorJon Seymour <jon.seymour@gmail.com>2012-06-06 11:57:30 (GMT)
committerJunio C Hamano <gitster@pobox.com>2012-06-06 18:43:55 (GMT)
commit758615e2517db8b9fda9218afded06a3e1b42e20 (patch)
tree37a6269f16ea0852b6a68b4c6f9c57fe119a67d9 /t/t7403-submodule-sync.sh
parent967b2c66738fe6b168ead0c3106ac47fb9ae22c7 (diff)
downloadgit-758615e2517db8b9fda9218afded06a3e1b42e20.zip
git-758615e2517db8b9fda9218afded06a3e1b42e20.tar.gz
git-758615e2517db8b9fda9218afded06a3e1b42e20.tar.bz2
submodule: fix handling of superproject origin URLs like foo, ./foo and ./foo/bar
Currently git submodule init and git submodule sync fail with an error if the superproject origin URL is of the form foo but succeed if the superproject origin URL is of the form ./foo or ./foo/bar or foo/bar. This change makes handling of the foo case behave like the handling of the ./foo case and also ensures that superfluous leading and embedded ./'s are removed from the resulting derived URLs. Signed-off-by: Jon Seymour <jon.seymour@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't/t7403-submodule-sync.sh')
-rwxr-xr-xt/t7403-submodule-sync.sh6
1 files changed, 3 insertions, 3 deletions
diff --git a/t/t7403-submodule-sync.sh b/t/t7403-submodule-sync.sh
index 98bc74a..524d5c1 100755
--- a/t/t7403-submodule-sync.sh
+++ b/t/t7403-submodule-sync.sh
@@ -88,7 +88,7 @@ test_expect_success '"git submodule sync" should not vivify uninteresting submod
)
'
-test_expect_failure '"git submodule sync" handles origin URL of the form foo' '
+test_expect_success '"git submodule sync" handles origin URL of the form foo' '
(cd relative-clone &&
git remote set-url origin foo &&
git submodule sync &&
@@ -110,7 +110,7 @@ test_expect_success '"git submodule sync" handles origin URL of the form foo/bar
)
'
-test_expect_failure '"git submodule sync" handles origin URL of the form ./foo' '
+test_expect_success '"git submodule sync" handles origin URL of the form ./foo' '
(cd relative-clone &&
git remote set-url origin ./foo &&
git submodule sync &&
@@ -121,7 +121,7 @@ test_expect_failure '"git submodule sync" handles origin URL of the form ./foo'
)
'
-test_expect_failure '"git submodule sync" handles origin URL of the form ./foo/bar' '
+test_expect_success '"git submodule sync" handles origin URL of the form ./foo/bar' '
(cd relative-clone &&
git remote set-url origin ./foo/bar &&
git submodule sync &&