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.



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

def initialize(step)
  @step = step
end

Instance Attribute Details

#stepObject (readonly)

Returns the value of attribute step.



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

def step
  @step
end

Instance Method Details

#error?Boolean

Returns:

  • (Boolean)


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

def error?
  !failure?
end

#failure?Boolean

Returns:

  • (Boolean)


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

def failure?
  true
end

#locationObject



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

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

#messageObject



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

def message
  step.exception.message
end

#nameObject



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

def name
  step.exception.class.name
end