Sha256: 64422de69f27c1f1e6419ec6c2ed223a58a260fda70b69ec62d1eafbc6dc7654

Contents?: true

Size: 415 Bytes

Versions: 10

Compression:

Stored size: 415 Bytes

Contents

require 'spec_helper'

describe Virtus::Attribute::Collection, '#member_type' do
  subject { object.member_type }

  context 'when specified' do
    let(:object) { Virtus::Attribute::Set.new('stuff', :member_type => Integer) }

    it { should be(Integer) }
  end

  context 'when not specified' do
    let(:object) { Virtus::Attribute::Set.new('stuff') }

    it { should be(Virtus::Attribute::Object) }
  end
end

Version data entries

10 entries across 10 versions & 2 rubygems

Version Path
virtus-0.5.5 spec/unit/virtus/attribute/collection/member_type_spec.rb
virtus-0.5.4 spec/unit/virtus/attribute/collection/member_type_spec.rb
virtus-0.5.3 spec/unit/virtus/attribute/collection/member_type_spec.rb
fragrant-0.0.5 vendor/bundle/ruby/1.9.1/gems/virtus-0.5.2/spec/unit/virtus/attribute/collection/member_type_spec.rb
virtus-0.5.2 spec/unit/virtus/attribute/collection/member_type_spec.rb
virtus-0.5.1 spec/unit/virtus/attribute/collection/member_type_spec.rb
virtus-0.5.0 spec/unit/virtus/attribute/collection/member_type_spec.rb
virtus-0.4.2 spec/unit/virtus/attribute/collection/member_type_spec.rb
virtus-0.4.1 spec/unit/virtus/attribute/collection/member_type_spec.rb
virtus-0.4.0 spec/unit/virtus/attribute/collection/member_type_spec.rb