Commit 643b9d8

mokha <mokha@cisco.com>
2018-09-22 16:54:46
escape HTML in oauth spec
1 parent edb2bd7
Changed files (1)
spec
spec/requests/oauth_spec.rb
@@ -15,7 +15,7 @@ RSpec.describe '/oauth' do
         context "when the correct parameters are provided" do
           before { get "/oauth", params: { client_id: client.to_param, response_type: 'code', state: state } }
           specify { expect(response).to have_http_status(:ok) }
-          specify { expect(response.body).to include(client.name) }
+          specify { expect(response.body).to include(CGI.escapeHTML(client.name)) }
           specify { expect(response.body).to include(state) }
         end