Class: ParallelTests::Cucumber::FailuresLogger

Inherits:
Cucumber::Formatter::Rerun
  • Object
show all
Includes:
Gherkin::Io
Defined in:
lib/parallel_tests/cucumber/failures_logger.rb

Instance Method Summary collapse

Methods included from Gherkin::Io

#lock_output, #prepare_io

Constructor Details

#initialize(config) ⇒ FailuresLogger

Returns a new instance of FailuresLogger.



10
11
12
13
# File 'lib/parallel_tests/cucumber/failures_logger.rb', line 10

def initialize(config)
  super
  @io = prepare_io(config.out_stream)
end

Instance Method Details

#doneObject



15
16
17
18
19
20
21
22
23
24
# File 'lib/parallel_tests/cucumber/failures_logger.rb', line 15

def done
  return if @failures.empty?
  lock_output do
    @failures.each do |file, lines|
      lines.each do |line|
        @io.print "#{file}:#{line} "
      end
    end
  end
end