diff options
author | Junio C Hamano <gitster@pobox.com> | 2012-03-08 13:04:52 -0800 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2012-03-08 13:04:52 -0800 |
commit | 7ac6609d9afde0d56705842fd60abb41715c1d1e (patch) | |
tree | 94cef0f47010b1c306b0a29df22026a6e5fc8fd0 /t/t7406-submodule-update.sh | |
parent | aa145bf6f1cb45ad66250c40da3cd708956cf71e (diff) | |
parent | 4dce7d9b408b2935b85721b54a2010eda7ec1be9 (diff) | |
download | git-7ac6609d9afde0d56705842fd60abb41715c1d1e.tar.gz git-7ac6609d9afde0d56705842fd60abb41715c1d1e.tar.xz |
Merge branch 'jl/maint-submodule-relative'
By Jens Lehmann (3) and Johannes Sixt (1)
* jl/maint-submodule-relative:
submodules: fix ambiguous absolute paths under Windows
submodules: refactor computation of relative gitdir path
submodules: always use a relative path from gitdir to work tree
submodules: always use a relative path to gitdir
Diffstat (limited to 't/t7406-submodule-update.sh')
-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 5b97222c4..dcb195b4c 100755 --- a/t/t7406-submodule-update.sh +++ b/t/t7406-submodule-update.sh @@ -619,4 +619,21 @@ test_expect_success 'submodule add properly re-creates deeper level submodules' ) ' +test_expect_success 'submodule update properly revives a moved submodule' ' + (cd super && + git commit -am "pre move" && + git status >expect&& + H=$(cd submodule2; git rev-parse HEAD) && + git rm --cached submodule2 && + rm -rf submodule2 && + mkdir -p "moved/sub module" && + git update-index --add --cacheinfo 160000 $H "moved/sub module" && + git config -f .gitmodules submodule.submodule2.path "moved/sub module" + git commit -am "post move" && + git submodule update && + git status >actual && + test_cmp expect actual + ) +' + test_done |