diff options
author | Sven Verdoolaege <skimo@kotnet.org> | 2007-07-17 20:28:28 +0200 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2007-07-18 17:01:00 -0700 |
commit | 0cf7375542504e3762753cdc4cff3bb5c8fc628e (patch) | |
tree | 787d4b62db0742483ec9c0af1c25d8e2fa106e7c /t/t7400-submodule-basic.sh | |
parent | c1c10a3f272ec0908e63bc105a5ffe94c1279fba (diff) | |
download | git-0cf7375542504e3762753cdc4cff3bb5c8fc628e.tar.gz |
unpack-trees.c: assume submodules are clean during check-out
In particular, when moving back to a commit without a given submodule
and then moving back forward to a commit with the given submodule,
we shouldn't complain that updating would lose untracked file in
the submodule, because git currently does not checkout subprojects
during superproject check-out.
Signed-off-by: Sven Verdoolaege <skimo@kotnet.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't/t7400-submodule-basic.sh')
-rwxr-xr-x | t/t7400-submodule-basic.sh | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/t/t7400-submodule-basic.sh b/t/t7400-submodule-basic.sh index 5e91db64e9..e8ce7cdb83 100755 --- a/t/t7400-submodule-basic.sh +++ b/t/t7400-submodule-basic.sh @@ -21,6 +21,10 @@ subcommands of git-submodule. # -add an entry to .gitmodules for submodule 'example' # test_expect_success 'Prepare submodule testing' ' + : > t && + git-add t && + git-commit -m "initial commit" && + git branch initial HEAD && mkdir lib && cd lib && git init && @@ -166,4 +170,9 @@ test_expect_success 'status should be "up-to-date" after update' ' git-submodule status | grep "^ $rev1" ' +test_expect_success 'checkout superproject with subproject already present' ' + git-checkout initial && + git-checkout master +' + test_done |