]> git.ipfire.org Git - thirdparty/git.git/blobdiff - t/t3906-stash-submodule.sh
Merge branch 'dl/test-must-fail-fixes-5'
[thirdparty/git.git] / t / t3906-stash-submodule.sh
index b93d1d74da7b41c51ba483fc015ac56f13799341..a52e53dd2da481e3c24a82d9599a58c0d1c5ab43 100755 (executable)
@@ -8,7 +8,12 @@ test_description='stash can handle submodules'
 git_stash () {
        git status -su >expect &&
        ls -1pR * >>expect &&
-       git read-tree -u -m "$1" &&
+       may_only_be_test_must_fail "$2" &&
+       $2 git read-tree -u -m "$1" &&
+       if test -n "$2"
+       then
+               return
+       fi &&
        git stash &&
        git status -su >actual &&
        ls -1pR * >>actual &&
@@ -19,7 +24,7 @@ git_stash () {
 KNOWN_FAILURE_STASH_DOES_IGNORE_SUBMODULE_CHANGES=1
 KNOWN_FAILURE_CHERRY_PICK_SEES_EMPTY_COMMIT=1
 KNOWN_FAILURE_NOFF_MERGE_DOESNT_CREATE_EMPTY_SUBMODULE_DIR=1
-test_submodule_switch "git_stash"
+test_submodule_switch_func "git_stash"
 
 setup_basic () {
        test_when_finished "rm -rf main sub" &&