Sha256: 744cd7f71d0fb5f3c7316ecca7573c818cd22868b9ab7bbc51325fe3f8649de8
Contents?: true
Size: 705 Bytes
Versions: 13
Compression:
Stored size: 705 Bytes
Contents
# frozen_string_literal: true RSpec.describe Blacklight::FieldRetriever, api: true do let(:service) { described_class.new(document, blacklight_field_config) } let(:blacklight_field_config) { Blacklight::Configuration::Field.new(field: 'author_field', highlight: true) } let(:document) { SolrDocument.new({ 'id' => 'doc1', 'title_field' => 'doc1 title', 'author_field' => 'author_someone' }, 'highlighting' => { 'doc1' => { 'title_tsimext' => ['doc <em>1</em>'] } }) } let(:view_context) { {} } context "highlighting" do describe '#fetch' do it "retrieves an author even if it's not highlighted" do expect(service.fetch).to eq(['author_someone']) end end end end
Version data entries
13 entries across 13 versions & 2 rubygems