diff options
author | Junio C Hamano <gitster@pobox.com> | 2017-01-23 15:59:21 -0800 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2017-01-23 15:59:21 -0800 |
commit | e801be066cc12799cd053a5b4eb792d9007133fc (patch) | |
tree | e09cc3c92b94f6e426f6f06da8efc623305253a2 /t | |
parent | Merge branch 'sb/submodule-embed-gitdir' (diff) | |
parent | submodule update --init: display correct path from submodule (diff) | |
download | tgif-e801be066cc12799cd053a5b4eb792d9007133fc.tar.xz |
Merge branch 'sb/submodule-init'
Error message fix.
* sb/submodule-init:
submodule update --init: display correct path from submodule
Diffstat (limited to 't')
-rwxr-xr-x | t/t7406-submodule-update.sh | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/t/t7406-submodule-update.sh b/t/t7406-submodule-update.sh index 64f322c4cc..725bbed1f8 100755 --- a/t/t7406-submodule-update.sh +++ b/t/t7406-submodule-update.sh @@ -140,6 +140,23 @@ test_expect_success 'submodule update --init --recursive from subdirectory' ' test_i18ncmp expect2 actual2 ' +cat <<EOF >expect2 +Submodule 'foo/sub' ($pwd/withsubs/../rebasing) registered for path 'sub' +EOF + +test_expect_success 'submodule update --init from and of subdirectory' ' + git init withsubs && + (cd withsubs && + mkdir foo && + git submodule add "$(pwd)/../rebasing" foo/sub && + (cd foo && + git submodule deinit -f sub && + git submodule update --init sub 2>../../actual2 + ) + ) && + test_i18ncmp expect2 actual2 +' + apos="'"; test_expect_success 'submodule update does not fetch already present commits' ' (cd submodule && |