Method: Cucumber::Ast::StepInvocation#failed

Defined in:
lib/cucumber/ast/step_invocation.rb

#failed(options, e, clear_backtrace) ⇒ Object



81
82
83
84
85
86
87
88
89
90
91
# File 'lib/cucumber/ast/step_invocation.rb', line 81

def failed(options, e, clear_backtrace)
  e = filter_backtrace(e)
  e.set_backtrace([]) if clear_backtrace
  e.backtrace << @step.backtrace_line unless @step.backtrace_line.nil?
  @exception = e
  if(options[:strict] || !(Undefined === e) || e.nested?)
    @reported_exception = e
  else
    @reported_exception = nil
  end
end