summaryrefslogtreecommitdiff
path: root/danger/roulette/Dangerfile
diff options
context:
space:
mode:
Diffstat (limited to 'danger/roulette/Dangerfile')
-rw-r--r--danger/roulette/Dangerfile13
1 files changed, 12 insertions, 1 deletions
diff --git a/danger/roulette/Dangerfile b/danger/roulette/Dangerfile
index 54b46807241..4eb1d987d84 100644
--- a/danger/roulette/Dangerfile
+++ b/danger/roulette/Dangerfile
@@ -48,10 +48,18 @@ Please consider creating a merge request to
for them.
MARKDOWN
+def group_not_available_template(slack_channel, gitlab_group)
+ <<~TEMPLATE
+ No engineer is available for automated assignment, please reach out to `#{slack_channel}` slack channel or mention `#{gitlab_group}` for assistance.
+ TEMPLATE
+end
+
OPTIONAL_REVIEW_TEMPLATE = '%{role} review is optional for %{category}'
NOT_AVAILABLE_TEMPLATES = {
default: 'No %{role} available',
- product_intelligence: "No engineer is available for automated assignment, please reach out to `#g_product_intelligence` slack channel or mention `@gitlab-org/growth/product-intelligence/engineers` for assistance."
+ product_intelligence: group_not_available_template('#g_product_intelligence', '@gitlab-org/growth/product-intelligence/engineers'),
+ integrations_be: group_not_available_template('#g_ecosystem_integrations', '@gitlab-org/ecosystem-stage/integrations'),
+ integrations_fe: group_not_available_template('#g_ecosystem_integrations', '@gitlab-org/ecosystem-stage/integrations')
}.freeze
def note_for_spins_role(spins, role, category)
@@ -96,6 +104,9 @@ categories = Set.new(changes.keys - [:unknown])
# Ensure to spin for database reviewer/maintainer when ~database is applied (e.g. to review SQL queries)
categories << :database if helper.mr_labels.include?('database')
+# Ensure to spin for UX reviewer for community contributions when ~UX is applied (e.g. to review changes to the UI)
+categories << :ux if (["UX", "Community contribution"] - helper.mr_labels).empty?
+
# Ensure to spin for Product Intelligence reviewer when ~"product intelligence::review pending" is applied
categories << :product_intelligence if helper.mr_labels.include?("product intelligence::review pending")