]> git.ipfire.org Git - thirdparty/git.git/commitdiff
t/t9NNN: allow local submodules
authorTaylor Blau <me@ttaylorr.com>
Fri, 29 Jul 2022 19:21:53 +0000 (15:21 -0400)
committerTaylor Blau <me@ttaylorr.com>
Sat, 1 Oct 2022 04:23:38 +0000 (00:23 -0400)
To prepare for the default value of `protocol.file.allow` to change to
"user", ensure tests that rely on local submodules can initialize them
over the file protocol.

Tests that interact with submodules a handful of times use
`test_config_global`.

Signed-off-by: Taylor Blau <me@ttaylorr.com>
t/t9304-fast-import-marks.sh
t/t9350-fast-export.sh

index d4359dba21c9cff29da7f96541e7c2293da759f3..73f3ca2b115015569bbda92f4a9464de58c64783 100755 (executable)
@@ -25,6 +25,7 @@ test_expect_success 'import with large marks file' '
 '
 
 test_expect_success 'setup dump with submodule' '
+       test_config_global protocol.file.allow always &&
        git submodule add "$PWD" sub &&
        git commit -m "add submodule" &&
        git fast-export HEAD >dump
index 137284255998ddd2653360cf614b265ead14d391..703428fd0a3f39ef9cce2ccb21d91397d0a9aee4 100755 (executable)
@@ -265,6 +265,7 @@ test_expect_success 'signed-tags=warn-strip' '
 
 test_expect_success 'setup submodule' '
 
+       test_config_global protocol.file.allow always &&
        git checkout -f master &&
        mkdir sub &&
        (
@@ -290,6 +291,7 @@ test_expect_success 'setup submodule' '
 
 test_expect_success 'submodule fast-export | fast-import' '
 
+       test_config_global protocol.file.allow always &&
        SUBENT1=$(git ls-tree master^ sub) &&
        SUBENT2=$(git ls-tree master sub) &&
        rm -rf new &&