Add new merge strategy in frontend as preferred
What does this MR do and why?
Related to #407352 (closed) and #8128 (closed).
This MR builds on top of !121828 (merged) and !121847 (merged).
It adds the new merge strategy to frontend and uses it as preferred over merge_when_pipeline_succeeds
.
Screenshots or screen recordings
Various scenarios
Approval is given before pipeline succeeds (same behavior as the current MWPS)
merge_when_checks_pass_approve_before
Approval is given after pipeline succeeds (new behavior that merges the MR)
merge_when_checks_pass_after_approval
Merge is clicked after the approval is given and pipeline succeeds (current behavior without auto-merge)
merge_when_checks_pass_all_pass_before
:merge_when_checks_pass
disabled (uses MWPS)
With feature flag
How to set up and validate locally
- Enable the feature flag
Feature.enable(:merge_when_checks_pass)
- Open an MR which requires approval
- Click "Set to auto-merge"
- Wait until pipeline succeeds
- Approve
- MR gets merged
Todos
MR acceptance checklist
This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.
-
I have evaluated the MR acceptance checklist for this MR.
Edited by Martin Čavoj