diff --git a/spec/controllers/search_controller_spec.rb b/spec/controllers/search_controller_spec.rb index 4db4133..81dcdce 100644 --- a/spec/controllers/search_controller_spec.rb +++ b/spec/controllers/search_controller_spec.rb @@ -28,6 +28,21 @@ RSpec.describe SearchController, type: :controller, elasticsearch: true do get :index, body: 'leipzig' end + + it "returns rss" do + get :index, :format => "rss", body: 'leipzig' + expect(response).to be_success + expect(response).to render_template(:index) + expect(response.content_type).to eq("application/rss+xml") + expect(response.body).to have_tag "rss" do + with_tag "channel" do + with_tag "title" + with_tag "description" + with_tag "link" + end + end + end + end end