Class: Warder::CoffeeLintRunner::MessageFormatter

Inherits:
Object
  • Object
show all
Defined in:
lib/warder/coffee_lint_runner/message_formatter.rb

Overview

responsible for human readable result of coffeelint validation

Instance Method Summary collapse

Constructor Details

#initialize(result) ⇒ MessageFormatter

Returns a new instance of MessageFormatter.



8
9
10
# File 'lib/warder/coffee_lint_runner/message_formatter.rb', line 8

def initialize(result)
  @result = result
end

Instance Method Details

#formatObject



12
13
14
15
16
# File 'lib/warder/coffee_lint_runner/message_formatter.rb', line 12

def format
  @result.map do |result|
    MessageLineFormatter.new(result).format
  end.join("\n")
end