Class: RBehave::Runner::ScenarioCollector
- Inherits:
-
Object
- Object
- RBehave::Runner::ScenarioCollector
- Defined in:
- lib/rbehave/runner/scenario_collector.rb
Instance Attribute Summary collapse
-
#scenarios ⇒ Object
Returns the value of attribute scenarios.
Instance Method Summary collapse
-
#initialize(story) ⇒ ScenarioCollector
constructor
A new instance of ScenarioCollector.
- #Scenario(name, &body) ⇒ Object
Constructor Details
#initialize(story) ⇒ ScenarioCollector
Returns a new instance of ScenarioCollector.
6 7 8 9 |
# File 'lib/rbehave/runner/scenario_collector.rb', line 6 def initialize(story) @story = story @scenarios = [] end |
Instance Attribute Details
#scenarios ⇒ Object
Returns the value of attribute scenarios.
4 5 6 |
# File 'lib/rbehave/runner/scenario_collector.rb', line 4 def scenarios @scenarios end |
Instance Method Details
#Scenario(name, &body) ⇒ Object
11 12 13 |
# File 'lib/rbehave/runner/scenario_collector.rb', line 11 def Scenario(name, &body) @scenarios << Scenario.new(@story, name, &body) end |