Class: RspecLogFormatter::Formatter::Factory

Inherits:
Object
  • Object
show all
Defined in:
lib/rspec_log_formatter/formatter.rb

Instance Method Summary collapse

Constructor Details

#initialize(options = {}) ⇒ Factory

Returns a new instance of Factory.


8
9
10
# File 'lib/rspec_log_formatter/formatter.rb', line 8

def initialize(options={})
  @options = options
end

Instance Method Details

#buildObject


12
13
14
15
16
17
18
19
20
# File 'lib/rspec_log_formatter/formatter.rb', line 12

def build
  opts = {
    clock: Time,
    build_number: ENV["BUILD_NUMBER"],
    limit_history: nil,
    output: $stdout
  }.merge(@options)
  RspecLogFormatter::Formatter.new(opts[:output], opts)
end