Sha256: 49cf55b7e98109d2a5601d4dd952a8bf38c53ce12ce2e82a91689c090ddfe2c1
Contents?: true
Size: 709 Bytes
Versions: 8
Compression:
Stored size: 709 Bytes
Contents
# frozen_string_literal: true RSpec.describe "catalog/_document_list" do let(:view_type) { 'some-view' } let(:view_config) { double(Blacklight::Configuration::ViewConfig) } before do allow(view_config).to receive_messages(key: view_type, document_component: Blacklight::DocumentComponent, partials: []) allow(view).to receive_messages(document_index_view_type: view_type, documents: [], blacklight_config: nil) assign(:response, instance_double(Blacklight::Solr::Response, start: 0)) end it "includes a class for the current view" do render(partial: "catalog/document_list", locals: { view_config: view_config }) expect(rendered).to have_css(".documents-some-view") end end
Version data entries
8 entries across 8 versions & 2 rubygems