rebase: remove a couple of redundant strategy tests
Remove a test in t3402 that has been redundant ever since 80ff47957b (rebase: remember strategy and strategy options, 2011-02-06). That commit added a new test, the first part of which (as noted in the old commit message) duplicated an existing test. Also remove a test t3418 that has been redundant since the merge backend was removed in 68aa495b59 (rebase: implement --merge via the interactive machinery, 2018-12-11), since it now tests the same code paths as the preceding test. Helped-by: Elijah Newren <newren@gmail.com> Reviewed-by: Elijah Newren <newren@gmail.com> Signed-off-by: Phillip Wood <phillip.wood@dunelm.org.uk> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Phillip Wood committed
Apr 10, 2023 at 10:08 UTC
05106aa198cd0f8a5643556ac9f8a1dfdbdb5bdd
2 files changed
-53
t/t3402-rebase-merge.sh
-21
@@ -131,27 +131,6 @@ test_expect_success 'picking rebase' '
131
esac
132
'
133
134
-test_expect_success 'rebase -s funny -Xopt' '
135
- test_when_finished "rm -fr test-bin funny.was.run" &&
136
- mkdir test-bin &&
137
- cat >test-bin/git-merge-funny <<-EOF &&
138
- #!$SHELL_PATH
139
- case "\$1" in --opt) ;; *) exit 2 ;; esac
140
- shift &&
141
- >funny.was.run &&
142
- exec git merge-recursive "\$@"
143
- EOF
144
- chmod +x test-bin/git-merge-funny &&
145
- git reset --hard &&
146
- git checkout -b test-funny main^ &&
147
- test_commit funny &&
148
- (
149
- PATH=./test-bin:$PATH &&
150
- git rebase -s funny -Xopt main
151
- ) &&
152
- test -f funny.was.run
153
-'
154
-
134
test_expect_success 'rebase --skip works with two conflicts in a row' '
135
git checkout second-side &&
136
tr "[A-Z]" "[a-z]" <newfile >tmp &&
t/t3418-rebase-continue.sh
-32
@@ -97,38 +97,6 @@ test_expect_success 'rebase --continue remembers merge strategy and options' '
97
test_cmp expect actual
98
'
99
100
-test_expect_success 'rebase -i --continue handles merge strategy and options' '
101
- rm -fr .git/rebase-* &&
102
- git reset --hard commit-new-file-F2-on-topic-branch &&
103
- test_commit "commit-new-file-F3-on-topic-branch-for-dash-i" F3 32 &&
104
- test_when_finished "rm -fr test-bin funny.was.run funny.args" &&
105
- mkdir test-bin &&
106
- cat >test-bin/git-merge-funny <<-EOF &&
107
- #!$SHELL_PATH
108
- echo "\$@" >>funny.args
109
- case "\$1" in --opt) ;; *) exit 2 ;; esac
110
- case "\$2" in --foo) ;; *) exit 2 ;; esac
111
- case "\$4" in --) ;; *) exit 2 ;; esac
112
- shift 2 &&
113
- >funny.was.run &&
114
- exec git merge-recursive "\$@"
115
- EOF
116
- chmod +x test-bin/git-merge-funny &&
117
- (
118
- PATH=./test-bin:$PATH &&
119
- test_must_fail git rebase -i -s funny -Xopt -Xfoo main topic
120
- ) &&
121
- test -f funny.was.run &&
122
- rm funny.was.run &&
123
- echo "Resolved" >F2 &&
124
- git add F2 &&
125
- (
126
- PATH=./test-bin:$PATH &&
127
- git rebase --continue
128
- ) &&
129
- test -f funny.was.run
130
-'
131
-
100
test_expect_success 'rebase -r passes merge strategy options correctly' '
101
rm -fr .git/rebase-* &&
102
git reset --hard commit-new-file-F3-on-topic-branch &&