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")