submodule: unset core.worktree if no working tree is present
[gitweb.git] / t / lib-submodule-update.sh
index 1f38a85371ab49790d14d3d4b82a0ee6e52789dd..12cd4e9233e345a1432e18b205e2833856a4425a 100755 (executable)
@@ -709,7 +709,8 @@ test_submodule_recursing_with_args_common() {
                        git branch -t remove_sub1 origin/remove_sub1 &&
                        $command remove_sub1 &&
                        test_superproject_content origin/remove_sub1 &&
-                       ! test -e sub1
+                       ! test -e sub1 &&
+                       test_must_fail git config -f .git/modules/sub1/config core.worktree
                )
        '
        # ... absorbing a .git directory along the way.