Sha256: 27b585fa82f495b1bc28aa9e92288cc9ec51a33511fb140aa9cc973a46972c99

Contents?: true

Size: 845 Bytes

Versions: 72

Compression:

Stored size: 845 Bytes

Contents

require File.dirname(__FILE__) + '/../story_helper'

module Spec
  module Story
    module Runner
      describe ScenarioCollector do
        it 'should construct scenarios with the supplied story' do
          # given
          story = stub_everything('story')
          scenario_collector = ScenarioCollector.new(story)
          
          # when
          scenario_collector.Scenario 'scenario1' do end
          scenario_collector.Scenario 'scenario2' do end
          scenarios = scenario_collector.scenarios
          
          # then
          scenario_collector.should have(2).scenarios
          scenarios.first.name.should == 'scenario1'
          scenarios.first.story.should equal(story)
          scenarios.last.name.should == 'scenario2'
          scenarios.last.story.should equal(story)
        end
      end
    end
  end
end

Version data entries

72 entries across 72 versions & 12 rubygems

Version Path
rspec-1.1.10 spec/spec/story/runner/scenario_collector_spec.rb
rspec-1.1.6 spec/spec/story/runner/scenario_collector_spec.rb
rspec-1.1.4 spec/spec/story/runner/scenario_collector_spec.rb
rspec-1.1.5 spec/spec/story/runner/scenario_collector_spec.rb
rspec-1.1.7 spec/spec/story/runner/scenario_collector_spec.rb
rspec-1.1.11 spec/spec/story/runner/scenario_collector_spec.rb
rspec-1.1.12 spec/spec/story/runner/scenario_collector_spec.rb
rspec-1.1.2 spec/spec/story/runner/scenario_collector_spec.rb
rspec-1.1.3 spec/spec/story/runner/scenario_collector_spec.rb
rspec-1.1.8 spec/spec/story/runner/scenario_collector_spec.rb
rspec-1.1.9 spec/spec/story/runner/scenario_collector_spec.rb
spree-0.2.0 vendor/plugins/rspec/spec/spec/story/runner/scenario_collector_spec.rb
spree-0.4.0 vendor/plugins/rspec/spec/spec/story/runner/scenario_collector_spec.rb
spree-0.4.1 vendor/plugins/rspec/spec/spec/story/runner/scenario_collector_spec.rb
spree-0.5.0 vendor/plugins/rspec/spec/spec/story/runner/scenario_collector_spec.rb
spree-0.6.0 vendor/plugins/rspec/spec/spec/story/runner/scenario_collector_spec.rb
spree-0.5.1 vendor/plugins/rspec/spec/spec/story/runner/scenario_collector_spec.rb
spree-0.7.0 vendor/plugins/rspec/spec/spec/story/runner/scenario_collector_spec.rb
spree-0.7.1 vendor/plugins/rspec/spec/spec/story/runner/scenario_collector_spec.rb
spree-0.8.0 vendor/plugins/rspec/spec/spec/story/runner/scenario_collector_spec.rb