Class: Qcumberless::Formatter

Inherits:
Cucumber::Formatter::Pretty
  • Object
show all
Defined in:
lib/qcumberless/formatter.rb

Instance Method Summary collapse

Instance Method Details

#before_step(step) ⇒ Object



5
6
7
8
9
10
11
# File 'lib/qcumberless/formatter.rb', line 5

def before_step( step )
  @io.printf("Step: ".indent(@scenario_indent + 2))
  @io.printf(step.name)
  @io.printf "\n"
  @io.flush
  super
end

#before_step_result(keyword, step_match, multiline_arg, status, exception, source_indent, background) ⇒ Object



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

def before_step_result(keyword, step_match, multiline_arg, status, exception, source_indent, background)
  if exception
    @io.printf("Step failed: ".indent(@scenario_indent + 2))
    @io.printf(exception)
    @io.printf("\n")
  end
  @io.flush
  super
end