diff options
author | Junio C Hamano <gitster@pobox.com> | 2016-03-24 12:27:12 -0700 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2016-03-24 12:27:13 -0700 |
commit | 2a4c8c36a7f6ad3520c0702f31dc7cff5176f1be (patch) | |
tree | 880686fbe5731690e0e81400c2be8fd5c418a4f4 /t | |
parent | 7e4ba3686ab04b2fdcb80f52e8784c9bebdb0401 (diff) | |
parent | 84ba959bbdf083ff7036619fa08152e46b9473a5 (diff) | |
download | git-2a4c8c36a7f6ad3520c0702f31dc7cff5176f1be.tar.gz |
Merge branch 'sb/submodule-module-list-pathspec-fix'
A fix for a small regression in "module_list" helper that was
rewritten in C (also applies to 2.7.x).
* sb/submodule-module-list-pathspec-fix:
submodule: fix regression for deinit without submodules
Diffstat (limited to 't')
-rwxr-xr-x | t/t7400-submodule-basic.sh | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/t/t7400-submodule-basic.sh b/t/t7400-submodule-basic.sh index be82a75e54..e1abd19230 100755 --- a/t/t7400-submodule-basic.sh +++ b/t/t7400-submodule-basic.sh @@ -849,6 +849,19 @@ test_expect_success 'set up a second submodule' ' git commit -m "submodule example2 added" ' +test_expect_success 'submodule deinit works on repository without submodules' ' + test_when_finished "rm -rf newdirectory" && + mkdir newdirectory && + ( + cd newdirectory && + git init && + >file && + git add file && + git commit -m "repo should not be empty" + git submodule deinit . + ) +' + test_expect_success 'submodule deinit should remove the whole submodule section from .git/config' ' git config submodule.example.foo bar && git config submodule.example2.frotz nitfol && |