Class: Cucumber::Formatter::RerunDump
- Inherits:
-
Object
- Object
- Cucumber::Formatter::RerunDump
- Includes:
- Io
- Defined in:
- lib/cucumber/formatter/rerun_dump.rb
Overview
Works like rerun but just outputs file location and line number Each new test is output to a new line
Instance Method Summary collapse
- #after_test_case(test_case, _result) ⇒ Object
- #done ⇒ Object
-
#initialize(_runtime, path_or_io, options) ⇒ RerunDump
constructor
A new instance of RerunDump.
Constructor Details
#initialize(_runtime, path_or_io, options) ⇒ RerunDump
Returns a new instance of RerunDump.
10 11 12 13 14 |
# File 'lib/cucumber/formatter/rerun_dump.rb', line 10 def initialize(_runtime, path_or_io, ) @io = ensure_io(path_or_io) @results = [] @options = end |
Instance Method Details
#after_test_case(test_case, _result) ⇒ Object
16 17 18 |
# File 'lib/cucumber/formatter/rerun_dump.rb', line 16 def after_test_case(test_case, _result) @results << [test_case.location.file, test_case.location.line] end |
#done ⇒ Object
20 21 22 23 |
# File 'lib/cucumber/formatter/rerun_dump.rb', line 20 def done return if @results.empty? @io.print file_failures.join("\n") end |