spec/helpers/spotlight/pages_helper_spec.rb in blacklight-spotlight-0.0.2 vs spec/helpers/spotlight/pages_helper_spec.rb in blacklight-spotlight-0.0.3

- old
+ new

@@ -3,10 +3,15 @@ module Spotlight describe PagesHelper do let(:blacklight_config) { Blacklight::Configuration.new { |config| config.show.title_field = :abc } } let(:titled_document) { ::SolrDocument.new( :abc => "value" ) } let(:untitled_document) { ::SolrDocument.new( :id => "1234" ) } - before(:each) { helper.stub(:blacklight_config => blacklight_config) } + let!(:current_exhibit) { Spotlight::Exhibit.default } + let!(:home_page) { current_exhibit.home_page } + + before(:each) do + helper.stub(:blacklight_config => blacklight_config) + end describe "has_title?" do it "should return true if the title is not the same as the ID" do expect(helper.has_title? titled_document).to be_true end