Class: Chelsea::JsonFormatter

Inherits:
Formatter show all
Defined in:
lib/chelsea/formatters/json.rb

Overview

Produce output in json format

Instance Method Summary collapse

Constructor Details

#initialize(options) ⇒ JsonFormatter

Returns a new instance of JsonFormatter.



25
26
27
28
# File 'lib/chelsea/formatters/json.rb', line 25

def initialize(options)
  super()
  @options = options
end

Instance Method Details

#do_print(result) ⇒ Object



34
35
36
# File 'lib/chelsea/formatters/json.rb', line 34

def do_print(result)
  puts result
end

#fetch_results(server_response, _reverse_deps) ⇒ Object



30
31
32
# File 'lib/chelsea/formatters/json.rb', line 30

def fetch_results(server_response, _reverse_deps)
  server_response.to_json
end