Class: Cucumber::Core::Ast::OutlineStep
- Inherits:
-
Object
- Object
- Cucumber::Core::Ast::OutlineStep
- Includes:
- DescribesItself, HasLocation
- Defined in:
- lib/cucumber/core/ast/outline_step.rb
Instance Attribute Summary collapse
-
#comments ⇒ Object
readonly
Returns the value of attribute comments.
-
#gherkin_statement ⇒ Object
readonly
Returns the value of attribute gherkin_statement.
-
#keyword ⇒ Object
readonly
Returns the value of attribute keyword.
-
#language ⇒ Object
readonly
Returns the value of attribute language.
-
#location ⇒ Object
readonly
Returns the value of attribute location.
-
#multiline_arg ⇒ Object
readonly
Returns the value of attribute multiline_arg.
-
#name ⇒ Object
readonly
Returns the value of attribute name.
Instance Method Summary collapse
-
#initialize(gherkin_statement, language, location, comments, keyword, name, multiline_arg) ⇒ OutlineStep
constructor
A new instance of OutlineStep.
- #inspect ⇒ Object
- #to_step(row) ⇒ Object
Methods included from DescribesItself
Methods included from HasLocation
#attributes, #file, #file_colon_line, #line, #match_locations?, #tags
Constructor Details
#initialize(gherkin_statement, language, location, comments, keyword, name, multiline_arg) ⇒ OutlineStep
Returns a new instance of OutlineStep.
15 16 17 18 |
# File 'lib/cucumber/core/ast/outline_step.rb', line 15 def initialize(gherkin_statement, language, location, comments, keyword, name, multiline_arg) @gherkin_statement, @language, @location, @comments, @keyword, @name, @multiline_arg = gherkin_statement, language, location, comments, keyword, name, multiline_arg @language || raise("Language is required!") end |
Instance Attribute Details
#comments ⇒ Object (readonly)
Returns the value of attribute comments.
13 14 15 |
# File 'lib/cucumber/core/ast/outline_step.rb', line 13 def comments @comments end |
#gherkin_statement ⇒ Object (readonly)
Returns the value of attribute gherkin_statement.
13 14 15 |
# File 'lib/cucumber/core/ast/outline_step.rb', line 13 def gherkin_statement @gherkin_statement end |
#keyword ⇒ Object (readonly)
Returns the value of attribute keyword.
13 14 15 |
# File 'lib/cucumber/core/ast/outline_step.rb', line 13 def keyword @keyword end |
#language ⇒ Object (readonly)
Returns the value of attribute language.
13 14 15 |
# File 'lib/cucumber/core/ast/outline_step.rb', line 13 def language @language end |
#location ⇒ Object (readonly)
Returns the value of attribute location.
13 14 15 |
# File 'lib/cucumber/core/ast/outline_step.rb', line 13 def location @location end |
#multiline_arg ⇒ Object (readonly)
Returns the value of attribute multiline_arg.
13 14 15 |
# File 'lib/cucumber/core/ast/outline_step.rb', line 13 def multiline_arg @multiline_arg end |
#name ⇒ Object (readonly)
Returns the value of attribute name.
13 14 15 |
# File 'lib/cucumber/core/ast/outline_step.rb', line 13 def name @name end |
Instance Method Details
#inspect ⇒ Object
24 25 26 27 |
# File 'lib/cucumber/core/ast/outline_step.rb', line 24 def inspect keyword_and_name = [keyword, name].join(": ") %{#<#{self.class} "#{keyword_and_name}" (#{location})>} end |
#to_step(row) ⇒ Object
20 21 22 |
# File 'lib/cucumber/core/ast/outline_step.rb', line 20 def to_step(row) Ast::ExpandedOutlineStep.new(self, gherkin_statement, language, row.location, comments, keyword, row.(name), replace_multiline_arg(row)) end |