Add external approvals rules to project settings
What does this MR do?
This MR adds external approvals to the project approval settings. This is part 2 of the MRs for #300973 (closed):
- Adds a new external approval type in project settings !57158 (merged)
- Add a type selector input to the add approval modal <- You are here
👈
What this MR changes:
- Adds a new external approval tule type
- Updates the approval rules to display approval gates
- Adds a
Approver Type
dropdown to theAdd approval rule
modal - Updates the approval rule form with a create & edit for external approval rules
- Updates the delete modal to also display for external approval rules
- Adds feature specs in
merge_requests_settings_spec.rb
- Refactors feature spec to use
let_it_be
Setup & Testing
- Enable the development feature flag:
echo "Feature.enable(:ff_compliance_approval_gates)" | rails c
- View
Merge request approvals
at[GDK_HOST]/gitlab-org/gitlab-shell/edit
Video walkthrough
Kapture_2021-04-09_at_12.08.25
Screenshots (strongly suggested)
Approvals list
Before | After |
---|---|
Approver form (Approver Type)
Before | After (User or Group) | After (Approval Gate) |
---|---|---|
Edit approver form
User or Group | Approval Gate |
---|---|
Delete modal
User or Group | Approval Gate |
---|---|
Does this MR meet the acceptance criteria?
Conformity
-
📋 Does this MR need a changelog?-
I have included a changelog entry. -
I have not included a changelog entry because it is behind a dev feature flag
.
-
- [-] Documentation (if required)
-
Code review guidelines -
Merge request performance guidelines -
Style guides - [-] Database guides
-
Separation of EE specific content
Availability and Testing
-
Review and add/update tests for this feature/bug. Consider all test levels. See the Test Planning Process. -
Tested in all supported browsers -
Informed Infrastructure department of a default or new setting change, if applicable per definition of done
Security
If this MR contains changes to processing or storing of credentials or tokens, authorization and authentication methods and other items described in the security review guidelines:
-
Label as security and @ mention @gitlab-com/gl-security/appsec
-
The MR includes necessary changes to maintain consistency between UI, API, email, or other methods -
Security reports checked/validated by a reviewer from the AppSec team
Related to #300973 (closed)
Edited by Jiaan Louw