Sha256: d954bed7baf5e71f792d164650b6f69948c2233eaa8a9654c6b7b816bc3772bf

Contents?: true

Size: 511 Bytes

Versions: 23

Compression:

Stored size: 511 Bytes

Contents

require 'test_helper'

module Vedeu

  module DSL

    describe Use do

      describe '.use' do
        context 'when an interface has not been defined' do
          it { proc { Vedeu.use('unknown') }.must_raise(ModelNotFound) }
        end

        it 'returns an instance of the named interface' do
          Vedeu.interface('aluminium') do
            # ...
          end

          Vedeu.use('aluminium').must_be_instance_of(Vedeu::Interface)
        end
      end

    end # Use

  end # DSL

end # Vedeu

Version data entries

23 entries across 23 versions & 1 rubygems

Version Path
vedeu-0.4.16 test/lib/vedeu/dsl/shared/use_test.rb
vedeu-0.4.15 test/lib/vedeu/dsl/shared/use_test.rb
vedeu-0.4.14 test/lib/vedeu/dsl/shared/use_test.rb
vedeu-0.4.13 test/lib/vedeu/dsl/shared/use_test.rb
vedeu-0.4.12 test/lib/vedeu/dsl/shared/use_test.rb
vedeu-0.4.11 test/lib/vedeu/dsl/shared/use_test.rb
vedeu-0.4.10 test/lib/vedeu/dsl/shared/use_test.rb
vedeu-0.4.9 test/lib/vedeu/dsl/shared/use_test.rb
vedeu-0.4.8 test/lib/vedeu/dsl/shared/use_test.rb
vedeu-0.4.7 test/lib/vedeu/dsl/shared/use_test.rb
vedeu-0.4.6 test/lib/vedeu/dsl/shared/use_test.rb
vedeu-0.4.5 test/lib/vedeu/dsl/shared/use_test.rb
vedeu-0.4.4 test/lib/vedeu/dsl/shared/use_test.rb
vedeu-0.4.3 test/lib/vedeu/dsl/shared/use_test.rb
vedeu-0.4.2 test/lib/vedeu/dsl/shared/use_test.rb
vedeu-0.4.1 test/lib/vedeu/dsl/shared/use_test.rb
vedeu-0.4.0 test/lib/vedeu/dsl/shared/use_test.rb
vedeu-0.3.5 test/lib/vedeu/dsl/shared/use_test.rb
vedeu-0.3.4 test/lib/vedeu/dsl/shared/use_test.rb
vedeu-0.3.3 test/lib/vedeu/dsl/shared/use_test.rb