Module: Cucumber::Core::Ast::Names

Included in:
Background, ExamplesTable, Feature, Scenario, ScenarioOutline
Defined in:
lib/cucumber/core/ast/names.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#descriptionObject (readonly)

Returns the value of attribute description.



5
6
7
# File 'lib/cucumber/core/ast/names.rb', line 5

def description
  @description
end

Instance Method Details

#inspectObject



26
27
28
29
# File 'lib/cucumber/core/ast/names.rb', line 26

def inspect
  keyword_and_name = [keyword, name].join(": ")
  %{#<#{self.class} "#{keyword_and_name}" (#{location})>}
end

#legacy_conflated_name_and_descriptionObject



16
17
18
19
20
# File 'lib/cucumber/core/ast/names.rb', line 16

def legacy_conflated_name_and_description
  s = @title
  s += "\n#{@description}" if @description != ""
  s
end

#nameObject



7
8
9
# File 'lib/cucumber/core/ast/names.rb', line 7

def name
  title
end

#titleObject



11
12
13
14
# File 'lib/cucumber/core/ast/names.rb', line 11

def title
  warn("deprecated. Use #name")
  @title
end

#to_sObject



22
23
24
# File 'lib/cucumber/core/ast/names.rb', line 22

def to_s
  @title
end