Sha256: 4d08ba65ccf1a6c9d0c4f3adadebaab0c57139af2c64c6f9719ac8a68c04ca08

Contents?: true

Size: 444 Bytes

Versions: 3

Compression:

Stored size: 444 Bytes

Contents

require 'spec_helper'

RSpec.describe Attachment, type: :model, attachments: true do
  it_behaves_like "a DDR model"
  it_behaves_like "an object that can have content"
  it_behaves_like "it has an association", :belongs_to, :attached_to, :is_attached_to, "ActiveFedora::Base"
  context "validations" do
    before { subject.valid? }
    it "should have content" do
      expect(subject.errors.messages).to have_key(:content)
    end
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
ddr-models-1.3.0 spec/models/attachment_spec.rb
ddr-models-1.2.1 spec/models/attachment_spec.rb
ddr-models-1.2.0 spec/models/attachment_spec.rb