Sha256: abf432dfd5a0d31670002237655cc2ec85087ef691e9ec26d0be1f790a897f74

Contents?: true

Size: 599 Bytes

Versions: 33

Compression:

Stored size: 599 Bytes

Contents

describe Spotlight::SolrDocumentSidecar, type: :model do
  let(:exhibit) { FactoryGirl.create(:exhibit) }
  before do
    allow(subject).to receive_messages exhibit: exhibit
    allow(subject).to receive_messages document: SolrDocument.new(id: 'doc_id')
  end

  describe '#to_solr' do
    before do
      subject.data = { 'a_tesim' => 1, 'b_tesim' => 2, 'c_tesim' => 3 }
    end

    its(:to_solr) { should include id: 'doc_id' }
    its(:to_solr) { should include "exhibit_#{exhibit.slug}_public_bsi".to_sym => true }
    its(:to_solr) { should include 'a_tesim', 'b_tesim', 'c_tesim' }
  end
end

Version data entries

33 entries across 33 versions & 1 rubygems

Version Path
blacklight-spotlight-1.0.0 spec/models/spotlight/solr_document_sidecar_spec.rb
blacklight-spotlight-1.0.0.alpha2 spec/models/spotlight/solr_document_sidecar_spec.rb
blacklight-spotlight-1.0.0.alpha1 spec/models/spotlight/solr_document_sidecar_spec.rb
blacklight-spotlight-0.34.1 spec/models/spotlight/solr_document_sidecar_spec.rb
blacklight-spotlight-0.34.0 spec/models/spotlight/solr_document_sidecar_spec.rb
blacklight-spotlight-0.33.3 spec/models/spotlight/solr_document_sidecar_spec.rb
blacklight-spotlight-0.33.2 spec/models/spotlight/solr_document_sidecar_spec.rb
blacklight-spotlight-0.33.1 spec/models/spotlight/solr_document_sidecar_spec.rb
blacklight-spotlight-0.33.0 spec/models/spotlight/solr_document_sidecar_spec.rb
blacklight-spotlight-0.32.0 spec/models/spotlight/solr_document_sidecar_spec.rb
blacklight-spotlight-0.31.0 spec/models/spotlight/solr_document_sidecar_spec.rb
blacklight-spotlight-0.30.0 spec/models/spotlight/solr_document_sidecar_spec.rb
blacklight-spotlight-0.29.1 spec/models/spotlight/solr_document_sidecar_spec.rb
blacklight-spotlight-0.29.0 spec/models/spotlight/solr_document_sidecar_spec.rb
blacklight-spotlight-0.28.3 spec/models/spotlight/solr_document_sidecar_spec.rb
blacklight-spotlight-0.28.2 spec/models/spotlight/solr_document_sidecar_spec.rb
blacklight-spotlight-0.28.1 spec/models/spotlight/solr_document_sidecar_spec.rb
blacklight-spotlight-0.28.0 spec/models/spotlight/solr_document_sidecar_spec.rb
blacklight-spotlight-0.27.0 spec/models/spotlight/solr_document_sidecar_spec.rb
blacklight-spotlight-0.26.1 spec/models/spotlight/solr_document_sidecar_spec.rb