Class: PullRequestSummarizer::ReviewChanges
- Inherits:
-
Object
- Object
- PullRequestSummarizer::ReviewChanges
- Defined in:
- lib/pull_request_summarizer/review_changes.rb
Instance Attribute Summary collapse
-
#popolo_files ⇒ Object
readonly
Returns the value of attribute popolo_files.
Instance Method Summary collapse
-
#initialize(popolo_before_after) ⇒ ReviewChanges
constructor
A new instance of ReviewChanges.
- #template ⇒ Object
- #to_html ⇒ Object
Constructor Details
#initialize(popolo_before_after) ⇒ ReviewChanges
Returns a new instance of ReviewChanges.
7 8 9 10 11 |
# File 'lib/pull_request_summarizer/review_changes.rb', line 7 def initialize(popolo_before_after) @popolo_files = popolo_before_after.map do |opts| ComparePopolo.parse(opts) end end |
Instance Attribute Details
#popolo_files ⇒ Object (readonly)
Returns the value of attribute popolo_files.
5 6 7 |
# File 'lib/pull_request_summarizer/review_changes.rb', line 5 def popolo_files @popolo_files end |
Instance Method Details
#template ⇒ Object
17 18 19 |
# File 'lib/pull_request_summarizer/review_changes.rb', line 17 def template @template ||= ERB.new(File.read('comment_template.md.erb')) end |
#to_html ⇒ Object
13 14 15 |
# File 'lib/pull_request_summarizer/review_changes.rb', line 13 def to_html template.result(binding) end |