Sha256: b56b539e0b79ae9378943ccca75bc157939c319b31a3b58c153828f6911078e7
Contents?: true
Size: 895 Bytes
Versions: 2
Compression:
Stored size: 895 Bytes
Contents
require 'spec_helper' describe Geoblacklight::DocumentPresenter do let(:request_context) { double(add_facet_params: '') } let(:config) { Blacklight::Configuration.new } subject { presenter } let(:presenter) do described_class.new(document, request_context, config) end let(:document) do SolrDocument.new(id: 1, layer_id_s: 'druid:abc123') end describe '#wxs_identifier' do describe 'without wxs identifier in configuration' do end it 'returns empty string' do expect(subject.wxs_identifier).to eq '' end describe 'without wxs identifier in configuration' do let(:config) do Blacklight::Configuration.new.configure do |config| config.wxs_identifier_field = 'layer_id_s' end end it 'returns configured field' do expect(subject.wxs_identifier).to eq 'druid:abc123' end end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
geoblacklight-0.12.1 | spec/lib/geoblacklight/document_presenter_spec.rb |
geoblacklight-0.12.0 | spec/lib/geoblacklight/document_presenter_spec.rb |