3 test_description
='cherry-pick can handle submodules'
5 GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME
=main
6 export GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME
9 .
"$TEST_DIRECTORY"/lib-submodule-update.sh
11 if test "$GIT_TEST_MERGE_ALGORITHM" != ort
13 KNOWN_FAILURE_NOFF_MERGE_DOESNT_CREATE_EMPTY_SUBMODULE_DIR
=1
14 KNOWN_FAILURE_NOFF_MERGE_ATTEMPTS_TO_MERGE_REMOVED_SUBMODULE_FILES
=1
16 test_submodule_switch
"cherry-pick"
18 test_expect_success
'unrelated submodule/file conflict is ignored' '
19 test_config_global protocol.file.allow always &&
21 test_create_repo sub &&
24 git -C sub add file &&
25 git -C sub commit -m "add a file in a submodule" &&
27 test_create_repo a_repo &&
32 git commit -m "add a file" &&
39 git add sub/content &&
40 git commit -m "add a regular folder with name sub" &&
44 git commit -m "modify a file" &&
48 git submodule add ../sub sub &&
49 git submodule update sub &&
50 git commit -m "add a submodule info folder with name sub" &&