From 1baa9a7d021f2c7e4cc9f4f9930a3145b9801284 Mon Sep 17 00:00:00 2001 From: JG Date: Mon, 20 Jun 2022 13:59:51 +0100 Subject: [PATCH] renamed expectations in test --- spec/components/search_result_caption_component_spec.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/spec/components/search_result_caption_component_spec.rb b/spec/components/search_result_caption_component_spec.rb index b628a4111..b62953867 100644 --- a/spec/components/search_result_caption_component_spec.rb +++ b/spec/components/search_result_caption_component_spec.rb @@ -9,7 +9,7 @@ RSpec.describe SearchResultCaptionComponent, type: :component do let(:item) { "schemes" } let(:path) { "path" } - it "all of the nav tabs specified in the items hash are passed to it" do + it "renders table caption including the search results and total" do result = render_inline(described_class.new(searched:, count:, item_label:, total_count:, item:, path:)) expect(result.to_html).to eq(" \n #{count} #{item_label} found matching ‘#{searched}’ of #{total_count} total #{item}. Clear search\n\n") end @@ -17,7 +17,7 @@ RSpec.describe SearchResultCaptionComponent, type: :component do context "when no search results are found" do let(:searched) { nil } - it "all of the nav tabs specified in the items hash are passed to it" do + it "renders table caption with total count only" do result = render_inline(described_class.new(searched:, count:, item_label:, total_count:, item:, path:)) expect(result.to_html).to eq(" \n #{count} total #{item}.\n\n")