Sha256: c4a3dcf83b46e7856f14832db2cf4cd096e96c267e612c87d866882aec838e37

Contents?: true

Size: 1.06 KB

Versions: 1

Compression:

Stored size: 1.06 KB

Contents

require 'test_helper'
class HoldingTest < Test::Unit::TestCase
  def setup
    @record_id = "aleph002895625"
  end

  def test_new_holding
    assert_nothing_raised {
      holding = Exlibris::Primo::Holding.new :record_id => @record_id,
        :original_id => @record_id, :title => "Holding Title", :author => "Holding Author", 
        :display_type => "Book"
      assert_equal "aleph002895625", holding.record_id
      assert_equal "aleph002895625", holding.original_id
      assert_equal "Holding Title", holding.title
      assert_equal "Holding Author", holding.author
      assert_equal "Book", holding.display_type
      assert_equal([], holding.coverage)
      assert_nil(holding.source_config)
      assert_nil(holding.source_class)
      assert_equal({}, holding.source_data)
      assert_equal(holding, holding.to_source)
      assert_equal([holding], holding.expand)
      assert((not holding.eql?(Exlibris::Primo::Holding.new)))
      assert(holding.eql?(holding))
      assert(holding, holding.merge!(holding))
      assert(holding.expand.include?(holding))
    }
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
exlibris-primo-1.0.7 test/holding_test.rb