summaryrefslogtreecommitdiff
path: root/t/t3504-cherry-pick-rerere.sh
AgeCommit message (Collapse)AuthorFilesLines
2020-01-27t3504: do check for conflict marker after failed cherry-pickLibravatar Johannes Sixt1-2/+4
The test with disabled rerere should make sure that the cherry-picked result does not have the conflict replaced with a recorded resolution. It attempts to do so by ensuring that the file content is _not_ equal to some other file. That by itself is a very dubious check because just about every random result of an incomplete cherry-pick would satisfy the condition. In this case, the intent was to check that the conflicting file does _not_ contain the resolved content. But the check actually uses the wrong reference file, but not the resolved content. Needless to say that the non-equality is satisfied. And, on top of it, it uses a commit that does not even touch the file that is checked. Do check for the expected result, which is content from both sides of the merge and merge conflicts. (The latter we check for just the middle separator for brevity.) As a side-effect, this also removes an incorrect use of test_must_fail. Signed-off-by: Johannes Sixt <j6t@kdbg.org> Signed-off-by: Denton Liu <liu.denton@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2017-08-02cherry-pick/revert: reject --rerere-autoupdate when continuingLibravatar Phillip Wood1-0/+13
cherry-pick and revert should not accept --[no-]rerere-autoupdate once they have started. Signed-off-by: Phillip Wood <phillip.wood@dunelm.org.uk> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2017-08-02cherry-pick/revert: remember --rerere-autoupdateLibravatar Phillip Wood1-7/+53
When continuing after conflicts, cherry-pick forgot if the user had specified '--rerere-autoupdate'. Redo the cherry-pick rerere tests to check --rerere-autoupdate works as expected. Signed-off-by: Phillip Wood <phillip.wood@dunelm.org.uk> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2017-08-02t3504: use test_commitLibravatar Phillip Wood1-12/+9
Using test_commit is simpler than chaining echo && git add && test_tick && commit. Also having tags makes it clearer which commit is being selecting by reset. Signed-off-by: Phillip Wood <phillip.wood@dunelm.org.uk> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-11-09tests: add missing &&Libravatar Jonathan Nieder1-2/+2
Breaks in a test assertion's && chain can potentially hide failures from earlier commands in the chain. Commands intended to fail should be marked with !, test_must_fail, or test_might_fail. The examples in this patch do not require that. Signed-off-by: Jonathan Nieder <jrnieder@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-08-11Make cherry-pick use rerere for conflict resolution.Libravatar Abhijit Menon-Sen1-0/+45
Cherry-picking can be helped by reusing previous confliction resolution by invoking rerere automatically. Signed-off-by: Abhijit Menon-Sen <ams@toroid.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>