class Cucumber::Core::Test::Result::Failed
def self.ok?(be_strict = false)
def self.ok?(be_strict = false) false end
def describe_to(visitor, *args)
def describe_to(visitor, *args) visitor.failed(*args) visitor.duration(duration, *args) visitor.exception(exception, *args) if exception self end
def initialize(duration, exception)
def initialize(duration, exception) raise ArgumentError unless duration raise ArgumentError unless exception @duration = duration @exception = exception end
def ok?(be_strict = nil)
def ok?(be_strict = nil) self.class.ok? end
def to_message
def to_message begin message = exception.backtrace.join("\n") rescue NoMethodError message = "" end Cucumber::Messages::TestStepResult.new( status: Cucumber::Messages::TestStepResultStatus::FAILED, duration: duration.to_message_duration, message: message ) end
def to_s
def to_s "✗" end
def with_appended_backtrace(step)
def with_appended_backtrace(step) exception.backtrace << step.backtrace_line if step.respond_to?(:backtrace_line) self end
def with_duration(new_duration)
def with_duration(new_duration) self.class.new(new_duration, exception) end
def with_filtered_backtrace(filter)
def with_filtered_backtrace(filter) self.class.new(duration, filter.new(exception.dup).exception) end