Class: Rgr::PlainReporter
- Inherits:
-
Object
- Object
- Rgr::PlainReporter
- Defined in:
- lib/rgr/plain_reporter.rb
Instance Attribute Summary collapse
-
#output ⇒ Object
readonly
Returns the value of attribute output.
Instance Method Summary collapse
-
#initialize(output = $stdout) ⇒ PlainReporter
constructor
A new instance of PlainReporter.
- #report_file_matches(file, matches) ⇒ Object
Constructor Details
#initialize(output = $stdout) ⇒ PlainReporter
Returns a new instance of PlainReporter.
5 6 7 |
# File 'lib/rgr/plain_reporter.rb', line 5 def initialize(output = $stdout) @output = output end |
Instance Attribute Details
#output ⇒ Object (readonly)
Returns the value of attribute output.
3 4 5 |
# File 'lib/rgr/plain_reporter.rb', line 3 def output @output end |
Instance Method Details
#report_file_matches(file, matches) ⇒ Object
9 10 11 12 13 |
# File 'lib/rgr/plain_reporter.rb', line 9 def report_file_matches(file, matches) matches.each do |match| puts "#{match.expression}: #{match.expression.source}" end end |