Class: CI::Reporter::CucumberFailure

Inherits:
Object
  • Object
show all
Defined in:
lib/ci/reporter/cucumber.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(step) ⇒ CucumberFailure

Returns a new instance of CucumberFailure.



24
25
26
# File 'lib/ci/reporter/cucumber.rb', line 24

def initialize(step)
  @step = step
end

Instance Attribute Details

#stepObject (readonly)

Returns the value of attribute step.



22
23
24
# File 'lib/ci/reporter/cucumber.rb', line 22

def step
  @step
end

Instance Method Details

#error?Boolean

Returns:

  • (Boolean)


32
33
34
# File 'lib/ci/reporter/cucumber.rb', line 32

def error?
  !failure?
end

#failure?Boolean

Returns:

  • (Boolean)


28
29
30
# File 'lib/ci/reporter/cucumber.rb', line 28

def failure?
  true
end

#locationObject



44
45
46
# File 'lib/ci/reporter/cucumber.rb', line 44

def location
  step.exception.backtrace.join("\n")
end

#messageObject



40
41
42
# File 'lib/ci/reporter/cucumber.rb', line 40

def message
  step.exception.message
end

#nameObject



36
37
38
# File 'lib/ci/reporter/cucumber.rb', line 36

def name
  step.exception.class.name
end