Sha256: 2c345999a53c07a7daf8b8b90c170ab77123eb917cb4520d5215a2dfe69ae8bb

Contents?: true

Size: 525 Bytes

Versions: 37

Compression:

Stored size: 525 Bytes

Contents

require 'test_helper'

module PushType
  class MenuBuilderTest < ActiveSupport::TestCase

    before  { MenuBuilder.class_variable_set :@@menus, {} }
    after   { MenuBuilder.class_variable_set :@@menus, {} }

    describe '.select' do
      it 'should create a new menu' do
        MenuBuilder.select(:foo).must_be_instance_of MenuBuilder::Menu
      end
      it 'should use existing menu if present' do
        menu = MenuBuilder.select(:bar)
        MenuBuilder.select(:bar).must_equal menu
      end
    end

  end
end

Version data entries

37 entries across 37 versions & 1 rubygems

Version Path
push_type_core-0.12.1 test/lib/push_type/menu_builder_test.rb
push_type_core-0.12.0 test/lib/push_type/menu_builder_test.rb
push_type_core-0.12.0.beta.1 test/lib/push_type/menu_builder_test.rb
push_type_core-0.11.2 test/lib/push_type/menu_builder_test.rb
push_type_core-0.11.1 test/lib/push_type/menu_builder_test.rb
push_type_core-0.11.0.beta.2 test/lib/push_type/menu_builder_test.rb
push_type_core-0.11.0.beta.1 test/lib/push_type/menu_builder_test.rb
push_type_core-0.10.4 test/lib/push_type/menu_builder_test.rb
push_type_core-0.10.3 test/lib/push_type/menu_builder_test.rb
push_type_core-0.10.2 test/lib/push_type/menu_builder_test.rb
push_type_core-0.10.1 test/lib/push_type/menu_builder_test.rb
push_type_core-0.10.0 test/lib/push_type/menu_builder_test.rb
push_type_core-0.10.0.beta.5 test/lib/push_type/menu_builder_test.rb
push_type_core-0.10.0.beta.3 test/lib/push_type/menu_builder_test.rb
push_type_core-0.9.5 test/lib/push_type/menu_builder_test.rb
push_type_core-0.9.3 test/lib/push_type/menu_builder_test.rb
push_type_core-0.9.2 test/lib/push_type/menu_builder_test.rb
push_type_core-0.9.1 test/lib/push_type/menu_builder_test.rb
push_type_core-0.9.0 test/lib/push_type/menu_builder_test.rb
push_type_core-0.9.0.beta.4 test/lib/push_type/menu_builder_test.rb