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.



13
14
15
# File 'lib/ci/reporter/cucumber.rb', line 13

def initialize(step)
  @step = step
end

Instance Attribute Details

#stepObject (readonly)

Returns the value of attribute step.



11
12
13
# File 'lib/ci/reporter/cucumber.rb', line 11

def step
  @step
end

Instance Method Details

#error?Boolean

Returns:

  • (Boolean)


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

def error?
  !failure?
end

#failure?Boolean

Returns:

  • (Boolean)


17
18
19
# File 'lib/ci/reporter/cucumber.rb', line 17

def failure?
  true
end

#locationObject



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

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

#messageObject



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

def message
  step.exception.message
end

#nameObject



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

def name
  step.exception.class.name
end