Skip to content

OpenProject is the leading open source project management software for product, project and portfolio management. A powerful Jira alternative with agile planning, issue tracking, roadmaps, Gantt charts, time tracking, collaboration features, and more. Available on premises or in the cloud. ⭐ Star us on GitHub

Assert redirect against `response.location` for provider_callback

Aaron Contrerasefb5e31063d1
diff --git a/spec/requests/openid_google_provider_callback_spec.rb b/spec/requests/openid_google_provider_callback_spec.rb
index 21f294622f6..ba991a6333f 100644
--- a/spec/requests/openid_google_provider_callback_spec.rb
+++ b/spec/requests/openid_google_provider_callback_spec.rb
@@ -97,6 +97,6 @@ RSpec.describe 'OpenID Google provider callback', with_ee: %i[openid_providers]
} do
response = get uri.to_s
expect(response.status).to eq(302)
- expect(response.body).to eq("<html><body>You are being <a href=\"http://example.org/two_factor_authentication/request\">redirected</a>.</body></html>")
+ expect(response.location).to eq("http://example.org/two_factor_authentication/request")
end
end