diff options
author | Junio C Hamano <gitster@pobox.com> | 2020-07-06 22:09:18 -0700 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2020-07-06 22:09:18 -0700 |
commit | efafdca42162843e90cefdeefd8e6c244cee91f5 (patch) | |
tree | 7cdfdc1a5604687c08b0a606af013d616877b028 /t/t3426-rebase-submodule.sh | |
parent | Merge branch 'jk/fast-export-anonym-alt' (diff) | |
parent | lib-submodule-update: pass 'test_must_fail' as an argument (diff) | |
download | tgif-efafdca42162843e90cefdeefd8e6c244cee91f5.tar.xz |
Merge branch 'dl/test-must-fail-fixes-5'
The effort to avoid using test_must_fail on non-git command continues.
* dl/test-must-fail-fixes-5:
lib-submodule-update: pass 'test_must_fail' as an argument
lib-submodule-update: prepend "git" to $command
lib-submodule-update: consolidate --recurse-submodules
lib-submodule-update: add space after function name
Diffstat (limited to 't/t3426-rebase-submodule.sh')
-rwxr-xr-x | t/t3426-rebase-submodule.sh | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/t/t3426-rebase-submodule.sh b/t/t3426-rebase-submodule.sh index a2bba04ba9..0ad3a07bf4 100755 --- a/t/t3426-rebase-submodule.sh +++ b/t/t3426-rebase-submodule.sh @@ -17,10 +17,11 @@ git_rebase () { git status -su >actual && ls -1pR * >>actual && test_cmp expect actual && - git rebase "$1" + may_only_be_test_must_fail "$2" && + $2 git rebase "$1" } -test_submodule_switch "git_rebase" +test_submodule_switch_func "git_rebase" git_rebase_interactive () { git status -su >expect && @@ -35,10 +36,11 @@ git_rebase_interactive () { test_cmp expect actual && set_fake_editor && echo "fake-editor.sh" >.git/info/exclude && - git rebase -i "$1" + may_only_be_test_must_fail "$2" && + $2 git rebase -i "$1" } -test_submodule_switch "git_rebase_interactive" +test_submodule_switch_func "git_rebase_interactive" test_expect_success 'rebase interactive ignores modified submodules' ' test_when_finished "rm -rf super sub" && |