assert_redirected_to 'my/page'
end
+ def test_login_with_invalid_openid_provider
+ Setting.self_registration = '0'
+ Setting.openid = '1'
+ post :login, :openid_url => 'http;//openid.example.com/good_user'
+ assert_redirected_to home_url
+ end
+
def test_login_with_openid_for_existing_non_active_user
Setting.self_registration = '2'
Setting.openid = '1'
begin
uri = URI.parse(identifier)
- uri.scheme = uri.scheme.downcase # URI should do this
+ uri.scheme = uri.scheme.downcase if uri.scheme # URI should do this
identifier = uri.normalize.to_s
rescue URI::InvalidURIError
raise InvalidOpenId.new("#{identifier} is not an OpenID identifier")