Class: Gitlab::Ci::Build::Rules::Result
- Inherits:
-
Struct
- Object
- Struct
- Gitlab::Ci::Build::Rules::Result
- Defined in:
- lib/gitlab/ci/build/rules.rb
Instance Attribute Summary collapse
-
#allow_failure ⇒ Object
Returns the value of attribute allow_failure.
-
#start_in ⇒ Object
Returns the value of attribute start_in.
-
#when ⇒ Object
Returns the value of attribute when.
Instance Method Summary collapse
Instance Attribute Details
#allow_failure ⇒ Object
Returns the value of attribute allow_failure
9 10 11 |
# File 'lib/gitlab/ci/build/rules.rb', line 9 def allow_failure @allow_failure end |
#start_in ⇒ Object
Returns the value of attribute start_in
9 10 11 |
# File 'lib/gitlab/ci/build/rules.rb', line 9 def start_in @start_in end |
#when ⇒ Object
Returns the value of attribute when
9 10 11 |
# File 'lib/gitlab/ci/build/rules.rb', line 9 def when @when end |
Instance Method Details
#build_attributes ⇒ Object
10 11 12 13 14 15 16 |
# File 'lib/gitlab/ci/build/rules.rb', line 10 def build_attributes { when: self.when, options: { start_in: start_in }.compact, allow_failure: allow_failure }.compact end |
#pass? ⇒ Boolean
18 19 20 |
# File 'lib/gitlab/ci/build/rules.rb', line 18 def pass? self.when != 'never' end |