summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLin Jen-Shin <godfat@godfat.org>2019-07-17 15:09:49 +0000
committerLin Jen-Shin <godfat@godfat.org>2019-07-17 15:09:49 +0000
commitf6399f1dfe7d2ff9f1bdfc278901b4919c85479f (patch)
tree8f15b68f9ec49247489a1d1ae49c7edaa1f755d3
parent4e457ebf824603ec2f76523345211360272ff98e (diff)
parent4f72293aaf36de46a0bd1615e7a4b2da92414be8 (diff)
downloadgitlab-ce-f6399f1dfe7d2ff9f1bdfc278901b4919c85479f.tar.gz
Merge branch 'danger-throughputs' into 'master'
Danger asks for throughput labels See merge request gitlab-org/gitlab-ce!30622
-rw-r--r--danger/metadata/Dangerfile12
1 files changed, 12 insertions, 0 deletions
diff --git a/danger/metadata/Dangerfile b/danger/metadata/Dangerfile
index 1adca152736..f2d68e64eb6 100644
--- a/danger/metadata/Dangerfile
+++ b/danger/metadata/Dangerfile
@@ -1,5 +1,13 @@
# rubocop:disable Style/SignalException
+THROUGHPUT_LABELS = [
+ 'Community contribution',
+ 'security',
+ 'bug',
+ 'feature',
+ 'backstage'
+].freeze
+
if gitlab.mr_body.size < 5
fail "Please provide a proper merge request description."
end
@@ -8,6 +16,10 @@ if gitlab.mr_labels.empty?
fail "Please add labels to this merge request."
end
+if (THROUGHPUT_LABELS & gitlab.mr_labels).empty?
+ warn 'Please add a [throughput label](https://about.gitlab.com/handbook/engineering/management/throughput/#implementation) to this merge request.'
+end
+
unless gitlab.mr_json["assignee"]
warn "This merge request does not have any assignee yet. Setting an assignee clarifies who needs to take action on the merge request at any given time."
end