spec/views/spotlight/pages/show.html.erb_spec.rb in blacklight-spotlight-2.13.0 vs spec/views/spotlight/pages/show.html.erb_spec.rb in blacklight-spotlight-3.0.0.alpha.1

- old
+ new

@@ -31,11 +31,11 @@ render end it 'does not double-escape HTML entities in the HTML title' do allow(page).to receive_messages(title: 'Abbott & Costello') - stub_template '_user_util_links.html.erb' => '' + stub_template 'shared/_user_util_links.html.erb' => '' stub_template 'shared/_masthead.html.erb' => '' render template: 'spotlight/pages/show', layout: 'layouts/spotlight/spotlight' expect(rendered).to have_content('Abbott & Costello | Blacklight') end @@ -51,16 +51,16 @@ end it 'renders the sidebar' do page.display_sidebar = true render - expect(rendered).to match('Sidebar') + expect(view.content_for(:sidebar)).to match('Sidebar') end it 'does not render the sidebar if the page has it disabled' do allow(page).to receive_messages(display_sidebar?: false) render - expect(rendered).to_not match('Sidebar') + expect(view.content_for(:sidebar)).to_not match('Sidebar') end it 'renders an empty partial if the page has no content' do allow(page).to receive_messages(content?: false) stub_template 'spotlight/pages/_empty.html.erb' => 'Empty message'