Sha256: 175f1e71b10f23c3cc7f782b54ee0655f4684930669e7e3688fe16dd09a5172c

Contents?: true

Size: 715 Bytes

Versions: 21

Compression:

Stored size: 715 Bytes

Contents

require 'spec_helper'

require 'active_fedora'
require 'active_fedora/model'

describe ActiveFedora::Property do
  before(:each) do
    @test_property = described_class.new(double("model_stub"), "file_name", :string)
  end

  it 'provides .new' do
    expect(described_class).to respond_to(:new)
  end

  it 'provides .name' do
    expect(described_class).to respond_to(:name)
  end

  it 'provides .instance_variable_name' do
    expect(@test_property).to respond_to(:instance_variable_name)
  end

  describe '.instance_variable_name' do
    it 'returns the value of the name attribute with an @ appended' do
      expect(@test_property.instance_variable_name).to eql("@#{@test_property.name}")
    end
  end
end

Version data entries

21 entries across 21 versions & 1 rubygems

Version Path
active-fedora-9.7.3 spec/unit/property_spec.rb
active-fedora-9.7.2 spec/unit/property_spec.rb
active-fedora-9.13.0 spec/unit/property_spec.rb
active-fedora-9.12.0 spec/unit/property_spec.rb
active-fedora-9.11.0 spec/unit/property_spec.rb
active-fedora-9.10.4 spec/unit/property_spec.rb
active-fedora-9.10.3 spec/unit/property_spec.rb
active-fedora-9.10.2 spec/unit/property_spec.rb
active-fedora-9.10.1 spec/unit/property_spec.rb
active-fedora-9.10.0 spec/unit/property_spec.rb
active-fedora-9.10.0.pre2 spec/unit/property_spec.rb
active-fedora-9.10.0.pre1 spec/unit/property_spec.rb
active-fedora-9.9.1 spec/unit/property_spec.rb
active-fedora-9.9.0 spec/unit/property_spec.rb
active-fedora-9.8.2 spec/unit/property_spec.rb
active-fedora-9.8.1 spec/unit/property_spec.rb
active-fedora-9.8.0 spec/unit/property_spec.rb
active-fedora-9.7.1 spec/unit/property_spec.rb
active-fedora-9.7.0 spec/unit/property_spec.rb
active-fedora-9.6.2 spec/unit/property_spec.rb