Sha256: d5c75d21ec8c898740ec85c4c5ea6d5029472a85c2741b3b16d3a65fefb7f13b

Contents?: true

Size: 889 Bytes

Versions: 8

Compression:

Stored size: 889 Bytes

Contents

require 'helper'

describe StageDefinition do
  let(:some_block) { Proc.new {} }

  describe "#requires" do
    it 'assigns the required injections' do
      subject.requires(:a, :b)
      subject.required_injections.should == [:a, :b]
    end
  end

  describe "#curtain_up" do
    it 'stores the block' do
      subject.curtain_up &some_block
      subject.curtain_up_block.should == some_block
    end
  end

  describe "#curtain_down" do
    it 'stores the block' do
      subject.curtain_down &some_block
      subject.curtain_down_block.should == some_block
    end
  end

  describe "#render_with" do
    it 'stores the renderer name' do
      subject.render_with :foopy
      subject.renderer.should == :foopy
    end
  end

  describe "#helpers" do
    it 'stores the block' do
      subject.helpers &some_block
      subject.helpers_block.should == some_block
    end
  end

end

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
gamebox-0.5.5 spec/core/stage_definition_spec.rb
gamebox-0.5.4 spec/core/stage_definition_spec.rb
gamebox-0.5.2 spec/core/stage_definition_spec.rb
gamebox-0.5.1 spec/core/stage_definition_spec.rb
gamebox-0.5.0 spec/core/stage_definition_spec.rb
gamebox-0.4.1 spec/core/stage_definition_spec.rb
gamebox-0.4.0 spec/core/stage_definition_spec.rb
gamebox-0.4.0.rc11 spec/core/stage_definition_spec.rb