From 552695297639afbf4382be1bbe35216dbc38af16 Mon Sep 17 00:00:00 2001 From: Chris Beer Date: Fri, 20 Sep 2024 12:21:38 -0700 Subject: [PATCH] Stub blacklight_config in view test. --- spec/views/shared/_header_navbar.html.erb_spec.rb | 1 + spec/views/spotlight/pages/show.html.erb_spec.rb | 1 + 2 files changed, 2 insertions(+) diff --git a/spec/views/shared/_header_navbar.html.erb_spec.rb b/spec/views/shared/_header_navbar.html.erb_spec.rb index b0679df13..99323113f 100644 --- a/spec/views/shared/_header_navbar.html.erb_spec.rb +++ b/spec/views/shared/_header_navbar.html.erb_spec.rb @@ -2,6 +2,7 @@ describe 'shared/_header_navbar', type: :view do before do + allow(view).to receive(:blacklight_config).and_return(Blacklight.default_configuration) stub_template 'shared/_user_util_links.html.erb' => 'links' end diff --git a/spec/views/spotlight/pages/show.html.erb_spec.rb b/spec/views/spotlight/pages/show.html.erb_spec.rb index e1066c3c1..e9d99b6f3 100644 --- a/spec/views/spotlight/pages/show.html.erb_spec.rb +++ b/spec/views/spotlight/pages/show.html.erb_spec.rb @@ -11,6 +11,7 @@ before do allow(view).to receive(:current_exhibit).and_return(exhibit) + allow(view).to receive(:blacklight_config).and_return(Blacklight.default_configuration) allow(view).to receive(:render_body_class).and_return('') assign(:page, page) stub_template 'spotlight/pages/_sidebar.html.erb' => 'Sidebar'