diff options
author | Grzegorz Bizon <grzesiek.bizon@gmail.com> | 2017-03-08 09:10:20 +0100 |
---|---|---|
committer | Grzegorz Bizon <grzesiek.bizon@gmail.com> | 2017-03-08 09:10:20 +0100 |
commit | 7319460c18a6a6dedaa4aa5c564bbe0afc1ee51c (patch) | |
tree | 52a486e30b90cf9e04e81764c29f6d20422ec624 /lib/gitlab | |
parent | cb19fd140fda6fd8adc05a00889e7567cabcaa62 (diff) | |
download | gitlab-ce-7319460c18a6a6dedaa4aa5c564bbe0afc1ee51c.tar.gz |
Verbosify blocked pipeline status description
Diffstat (limited to 'lib/gitlab')
-rw-r--r-- | lib/gitlab/ci/status/pipeline/blocked.rb | 23 | ||||
-rw-r--r-- | lib/gitlab/ci/status/pipeline/factory.rb | 3 |
2 files changed, 25 insertions, 1 deletions
diff --git a/lib/gitlab/ci/status/pipeline/blocked.rb b/lib/gitlab/ci/status/pipeline/blocked.rb new file mode 100644 index 00000000000..a250c3fcb41 --- /dev/null +++ b/lib/gitlab/ci/status/pipeline/blocked.rb @@ -0,0 +1,23 @@ +module Gitlab + module Ci + module Status + module Pipeline + class Blocked < SimpleDelegator + include Status::Extended + + def text + 'blocked' + end + + def label + 'waiting for manual action' + end + + def self.matches?(pipeline, user) + pipeline.blocked? + end + end + end + end + end +end diff --git a/lib/gitlab/ci/status/pipeline/factory.rb b/lib/gitlab/ci/status/pipeline/factory.rb index 13c8343b12a..17f9a75f436 100644 --- a/lib/gitlab/ci/status/pipeline/factory.rb +++ b/lib/gitlab/ci/status/pipeline/factory.rb @@ -4,7 +4,8 @@ module Gitlab module Pipeline class Factory < Status::Factory def self.extended_statuses - [Status::SuccessWarning] + [[Status::SuccessWarning, + Status::Pipeline::Blocked]] end def self.common_helpers |