Sha256: be51c7ea71d20156e3a9223f3891d95badb0100fa9914172ff1f82b39b83ac04
Contents?: true
Size: 711 Bytes
Versions: 2
Compression:
Stored size: 711 Bytes
Contents
# frozen_string_literal: true RSpec.describe Blacklight::Catalog do subject { controller } let(:controller) { (Class.new(ApplicationController) { include Blacklight::Catalog }).new } describe "#search_state" do subject { controller.send(:search_state) } let(:raw_params) { ActiveSupport::HashWithIndifferentAccess.new a: 1 } let(:params) { ActionController::Parameters.new raw_params } before do controller.blacklight_config.search_state_fields << :a allow(controller).to receive_messages(params: params) end it "creates a path object" do expect(subject).to be_kind_of Blacklight::SearchState expect(subject.params).to eq raw_params end end end
Version data entries
2 entries across 2 versions & 2 rubygems
Version | Path |
---|---|
blacklight-spotlight-3.6.0.beta8 | vendor/bundle/ruby/3.2.0/gems/blacklight-8.3.0/spec/controllers/blacklight/catalog_spec.rb |
blacklight-8.3.0 | spec/controllers/blacklight/catalog_spec.rb |