diff options
author | Zeger-Jan van de Weg <git@zjvandeweg.nl> | 2019-03-13 14:56:31 +0300 |
---|---|---|
committer | Jacob Vosmaer <jacob@gitlab.com> | 2019-03-13 14:56:31 +0300 |
commit | 3cf75dfc7c14956ebee3802cacd0f43672a54343 (patch) | |
tree | ce3f79d07048bbdf8982fec460855a2012164837 /danger | |
parent | d37e6a58001b363a2a74ecc6b3dcd09341aa9e2b (diff) |
Update labeling rules for GitalyBot
Today I noticed that the labeling as applied previously aren't correct
for the throughput measurements GitLab does:
https://about.gitlab.com/handbook/engineering/management/throughput/#implementation
This change updates the labeling rules so from now on this will be
correctly applied. In the case of Gitaly performance is a feature and
not backstage as the point of Gitaly is improving performance.
En passant it fixes a small issue when no changelog entry is present.
Diffstat (limited to 'danger')
-rw-r--r-- | danger/labels/Dangerfile | 19 |
1 files changed, 10 insertions, 9 deletions
diff --git a/danger/labels/Dangerfile b/danger/labels/Dangerfile index 9839b797c..cd27a323b 100644 --- a/danger/labels/Dangerfile +++ b/danger/labels/Dangerfile @@ -19,17 +19,18 @@ if GITALY_TEAM.include?(gitlab.mr_author) && !gitlab.mr_labels.include?("Gitaly" end TYPE_TO_LABEL = { - 'added' => 'feature', - 'fixed' => 'bug', - 'changed' => 'backstage', - 'deprecated' => 'backstage', - 'security' => 'security', - 'removed' => 'backstage', - 'performance' => 'performance', - 'other' => 'backstage', + 'added' => ['feature'], + 'fixed' => ['bug'], + 'changed' => ['backstage'], + 'deprecated' => ['backstage'], + 'security' => ['security'], + 'removed' => ['backstage'], + 'performance' => ['performance', 'backstage'], + 'other' => ['backstage'], + nil => [] } -required_labels << TYPE_TO_LABEL[changelog_entry["type"]] +required_labels.concat(TYPE_TO_LABEL[changelog_entry["type"]]) gitlab.api.update_merge_request( gitlab.mr_json['project_id'], |