Sha256: 2cbfa66a799ded94179ccc9bdf73598af355d5084038666001b6756ccd0fa447

Contents?: true

Size: 963 Bytes

Versions: 8

Compression:

Stored size: 963 Bytes

Contents

require File.expand_path(File.dirname(__FILE__) + '/../spec_helper')
require "active_fedora"

describe GenericContent do
  
  before(:each) do
    Fedora::Repository.stubs(:instance).returns(stub_everything())
    @hydra_content = GenericContent.new
  end
  
  it "Should be a kind of ActiveFedora::Base" do
    @hydra_content.should be_kind_of(ActiveFedora::Base)
  end
  
  it "should include Hydra Model Methods" do
    @hydra_content.class.included_modules.should include(Hydra::ModelMethods)
    @hydra_content.should respond_to(:apply_depositor_metadata)
  end
  
  it "should have accessors for its default datastreams of content and original" do
    @hydra_content.should respond_to(:has_content?)
    @hydra_content.should respond_to(:content)
    @hydra_content.should respond_to(:content=)
    @hydra_content.should respond_to(:has_original?)
    @hydra_content.should respond_to(:original)
    @hydra_content.should respond_to(:original=)
  end
  
end

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
hydra-head-3.0.1 test_support/spec/models/generic_content_spec.rb
hydra-head-3.0.0 test_support/spec/models/generic_content_spec.rb
hydra-head-3.0.0.rc2 test_support/spec/models/generic_content_spec.rb
hydra-head-3.0.0.rc1 test_support/spec/models/generic_content_spec.rb
hydra-head-3.0.0pre4 test_support/spec/models/generic_content_spec.rb
hydra-head-3.0.0pre3 test_support/spec/models/generic_content_spec.rb
hydra-head-3.0.0pre2 test_support/spec/models/generic_content_spec.rb
hydra-head-3.0.0pre1 test_support/spec/models/generic_content_spec.rb