Sha256: 7748a1bea54a50153a5265b8ca19362d6e999562b0305018f36edd9010b6d7ad
Contents?: true
Size: 711 Bytes
Versions: 54
Compression:
Stored size: 711 Bytes
Contents
require 'spec_helper' describe CurationConcerns::CollectionIndexer do let(:indexer) { described_class.new(collection) } let(:collection) { build(:collection) } describe "#generate_solr_document" do before do allow(collection).to receive(:bytes).and_return(1000) allow(CurationConcerns::ThumbnailPathService).to receive(:call).and_return("/downloads/1234?file=thumbnail") end subject { indexer.generate_solr_document } it "has required fields" do expect(subject.fetch('generic_type_sim')).to eq ["Collection"] expect(subject.fetch('bytes_lts')).to eq(1000) expect(subject.fetch('thumbnail_path_ss')).to eq "/downloads/1234?file=thumbnail" end end end
Version data entries
54 entries across 54 versions & 1 rubygems