Class: Cucumber::Formatter::LegacyApi::Ast::Scenario

Inherits:
Struct
  • Object
show all
Defined in:
lib/cucumber/formatter/legacy_api/ast.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#locationObject

Returns the value of attribute location

Returns:

  • (Object)

    the current value of location



281
282
283
# File 'lib/cucumber/formatter/legacy_api/ast.rb', line 281

def location
  @location
end

#nameObject

Returns the value of attribute name

Returns:

  • (Object)

    the current value of name



281
282
283
# File 'lib/cucumber/formatter/legacy_api/ast.rb', line 281

def name
  @name
end

#statusObject

Returns the value of attribute status

Returns:

  • (Object)

    the current value of status



281
282
283
# File 'lib/cucumber/formatter/legacy_api/ast.rb', line 281

def status
  @status
end

Instance Method Details

#backtrace_line(step_name = "#{name}", line = self.location.line) ⇒ Object



282
283
284
# File 'lib/cucumber/formatter/legacy_api/ast.rb', line 282

def backtrace_line(step_name = "#{name}", line = self.location.line)
  "#{location.on_line(line)}:in `#{step_name}'"
end

#failed?Boolean

Returns:

  • (Boolean)


286
287
288
# File 'lib/cucumber/formatter/legacy_api/ast.rb', line 286

def failed?
  :failed == status
end

#lineObject



290
291
292
# File 'lib/cucumber/formatter/legacy_api/ast.rb', line 290

def line
  location.line
end