Sha256: ea840ff0822cada1afc53ad4acae114c99979b36285d612f0cef240f1460b463
Contents?: true
Size: 677 Bytes
Versions: 9
Compression:
Stored size: 677 Bytes
Contents
# frozen_string_literal: true describe 'spotlight/sir_trevor/blocks/_browse_block.html.erb', type: :view do let(:p) { 'spotlight/sir_trevor/blocks/browse_block' } let(:page) { double('Page', display_sidebar?: true) } let(:search) { FactoryBot.create(:search) } let(:block) do assign(:page, page) SirTrevorRails::Blocks::BrowseBlock.new({ type: 'block', data: {} }, page) end before do allow(block).to receive(:searches).and_return([search]) end it 'links to the search' do render partial: p, locals: { browse_block: block } expect(rendered).to have_link search.title, href: spotlight.exhibit_browse_path(search.exhibit, search) end end
Version data entries
9 entries across 9 versions & 1 rubygems