Class: LucidTDL::AST::Scenario
- Includes:
- Enumerable
- Defined in:
- lib/lucid-tdl/ast.rb
Overview
class Background
Direct Known Subclasses
Instance Attribute Summary collapse
-
#name ⇒ Object
readonly
Returns the value of attribute name.
-
#steps ⇒ Object
readonly
Returns the value of attribute steps.
-
#tags ⇒ Object
readonly
Returns the value of attribute tags.
Attributes inherited from Node
Instance Method Summary collapse
- #each ⇒ Object
-
#initialize(name, steps = [], tags = []) ⇒ Scenario
constructor
A new instance of Scenario.
- #line ⇒ Object
Methods inherited from Node
Constructor Details
#initialize(name, steps = [], tags = []) ⇒ Scenario
Returns a new instance of Scenario.
65 66 67 68 69 |
# File 'lib/lucid-tdl/ast.rb', line 65 def initialize(name, steps=[], =[]) @name = name.to_s @steps = steps = end |
Instance Attribute Details
#name ⇒ Object (readonly)
Returns the value of attribute name.
63 64 65 |
# File 'lib/lucid-tdl/ast.rb', line 63 def name @name end |
#steps ⇒ Object (readonly)
Returns the value of attribute steps.
63 64 65 |
# File 'lib/lucid-tdl/ast.rb', line 63 def steps @steps end |
#tags ⇒ Object (readonly)
Returns the value of attribute tags.
63 64 65 |
# File 'lib/lucid-tdl/ast.rb', line 63 def end |
Instance Method Details
#each ⇒ Object
75 76 77 |
# File 'lib/lucid-tdl/ast.rb', line 75 def each @steps.each end |
#line ⇒ Object
71 72 73 |
# File 'lib/lucid-tdl/ast.rb', line 71 def line @steps.first.line - 1 if @steps.any? end |