Class: JenkinsJob::Common::Gerrit
- Inherits:
- BasicObject
- Defined in:
- lib/rubyjobbuilderdsl/common/gerrit.rb
Instance Attribute Summary collapse
-
#change_merged_ ⇒ Object
readonly
Returns the value of attribute change_merged_.
-
#comment_added_ ⇒ Object
readonly
Returns the value of attribute comment_added_.
-
#patchset_uploaded_ ⇒ Object
readonly
Returns the value of attribute patchset_uploaded_.
-
#projects_ ⇒ Object
readonly
Returns the value of attribute projects_.
Instance Method Summary collapse
- #change_merged(value = true) ⇒ Object
- #comment_added(param = {}) ⇒ Object
-
#initialize ⇒ Gerrit
constructor
A new instance of Gerrit.
- #patchset_uploaded(value = true) ⇒ Object
- #project(project, &block) ⇒ Object
Constructor Details
#initialize ⇒ Gerrit
6 7 8 9 |
# File 'lib/rubyjobbuilderdsl/common/gerrit.rb', line 6 def initialize @comment_added_ = [] @projects_ = [] end |
Instance Attribute Details
#change_merged_ ⇒ Object (readonly)
Returns the value of attribute change_merged_.
4 5 6 |
# File 'lib/rubyjobbuilderdsl/common/gerrit.rb', line 4 def change_merged_ @change_merged_ end |
#comment_added_ ⇒ Object (readonly)
Returns the value of attribute comment_added_.
4 5 6 |
# File 'lib/rubyjobbuilderdsl/common/gerrit.rb', line 4 def comment_added_ @comment_added_ end |
#patchset_uploaded_ ⇒ Object (readonly)
Returns the value of attribute patchset_uploaded_.
4 5 6 |
# File 'lib/rubyjobbuilderdsl/common/gerrit.rb', line 4 def patchset_uploaded_ @patchset_uploaded_ end |
#projects_ ⇒ Object (readonly)
Returns the value of attribute projects_.
4 5 6 |
# File 'lib/rubyjobbuilderdsl/common/gerrit.rb', line 4 def projects_ @projects_ end |
Instance Method Details
#change_merged(value = true) ⇒ Object
11 12 13 |
# File 'lib/rubyjobbuilderdsl/common/gerrit.rb', line 11 def change_merged(value = true) @change_merged_ = value end |
#comment_added(param = {}) ⇒ Object
19 20 21 22 23 24 25 26 |
# File 'lib/rubyjobbuilderdsl/common/gerrit.rb', line 19 def comment_added(param = {}) param.each do |k, v| @comment_added_ << { :approval_category => k, :approval_value => v } end end |
#patchset_uploaded(value = true) ⇒ Object
15 16 17 |
# File 'lib/rubyjobbuilderdsl/common/gerrit.rb', line 15 def patchset_uploaded(value = true) @patchset_uploaded_ = value end |
#project(project, &block) ⇒ Object
28 29 30 31 32 33 |
# File 'lib/rubyjobbuilderdsl/common/gerrit.rb', line 28 def project(project, &block) project = GerritProject.new(project) project.instance_eval(&block) @projects_ << project end |