Sha256: df5a76a3cc100160e4f8ac90465c735285b03198f838872b9717a0f0abfe6ee6

Contents?: true

Size: 840 Bytes

Versions: 16

Compression:

Stored size: 840 Bytes

Contents

# frozen_string_literal: true

describe 'spotlight/browse/_sort_and_per_page', type: :view do
  let :blacklight_config do
    Blacklight::Configuration.new
  end

  before do
    allow(view).to receive_messages(blacklight_config: blacklight_config)
  end

  it 'renders the pagination, sort, per page and view type controls' do
    stub_template '_paginate_compact.html.erb' => "paginate_compact\n"
    stub_template '_sort_widget.html.erb' => "sort_widget\n"
    stub_template '_per_page_widget.html.erb' => "per_page_widget\n"
    stub_template '_view_type_group.html.erb' => "view_type_group\n"
    render
    expect(rendered).to_not have_content 'paginate_compact'
    expect(rendered).to have_content 'sort_widget'
    expect(rendered).to have_content 'per_page_widget'
    expect(rendered).to have_content 'view_type_group'
  end
end

Version data entries

16 entries across 16 versions & 1 rubygems

Version Path
blacklight-spotlight-2.13.0 spec/views/spotlight/browse/_sort_and_per_page.html.erb_spec.rb
blacklight-spotlight-2.12.1 spec/views/spotlight/browse/_sort_and_per_page.html.erb_spec.rb
blacklight-spotlight-2.12.0 spec/views/spotlight/browse/_sort_and_per_page.html.erb_spec.rb
blacklight-spotlight-2.11.0 spec/views/spotlight/browse/_sort_and_per_page.html.erb_spec.rb
blacklight-spotlight-2.10.0 spec/views/spotlight/browse/_sort_and_per_page.html.erb_spec.rb
blacklight-spotlight-2.9.0 spec/views/spotlight/browse/_sort_and_per_page.html.erb_spec.rb
blacklight-spotlight-2.8.0 spec/views/spotlight/browse/_sort_and_per_page.html.erb_spec.rb
blacklight-spotlight-2.7.2 spec/views/spotlight/browse/_sort_and_per_page.html.erb_spec.rb
blacklight-spotlight-2.7.1 spec/views/spotlight/browse/_sort_and_per_page.html.erb_spec.rb
blacklight-spotlight-2.7.0 spec/views/spotlight/browse/_sort_and_per_page.html.erb_spec.rb
blacklight-spotlight-2.6.1.1 spec/views/spotlight/browse/_sort_and_per_page.html.erb_spec.rb
blacklight-spotlight-2.6.1 spec/views/spotlight/browse/_sort_and_per_page.html.erb_spec.rb
blacklight-spotlight-2.6.0 spec/views/spotlight/browse/_sort_and_per_page.html.erb_spec.rb
blacklight-spotlight-2.5.2 spec/views/spotlight/browse/_sort_and_per_page.html.erb_spec.rb
blacklight-spotlight-2.5.1 spec/views/spotlight/browse/_sort_and_per_page.html.erb_spec.rb
blacklight-spotlight-2.5.0 spec/views/spotlight/browse/_sort_and_per_page.html.erb_spec.rb