Update google auth endpoint to v2 #1307
This commit is contained in:
parent
cc8acdff57
commit
21acbf06e8
|
|
@ -12,7 +12,7 @@ namespace Microsoft.AspNetCore.Authentication.Google
|
|||
|
||||
public static readonly string DisplayName = "Google";
|
||||
|
||||
public static readonly string AuthorizationEndpoint = "https://accounts.google.com/o/oauth2/auth";
|
||||
public static readonly string AuthorizationEndpoint = "https://accounts.google.com/o/oauth2/v2/auth";
|
||||
|
||||
public static readonly string TokenEndpoint = "https://www.googleapis.com/oauth2/v4/token";
|
||||
|
||||
|
|
|
|||
|
|
@ -457,7 +457,7 @@ namespace Microsoft.AspNetCore.Authentication.Google
|
|||
var transaction = await server.SendAsync("https://example.com/challenge");
|
||||
Assert.Equal(HttpStatusCode.Redirect, transaction.Response.StatusCode);
|
||||
var location = transaction.Response.Headers.Location.ToString();
|
||||
Assert.Contains("https://accounts.google.com/o/oauth2/auth?response_type=code", location);
|
||||
Assert.Contains("https://accounts.google.com/o/oauth2/v2/auth?response_type=code", location);
|
||||
Assert.Contains("&client_id=", location);
|
||||
Assert.Contains("&redirect_uri=", location);
|
||||
Assert.Contains("&scope=", location);
|
||||
|
|
|
|||
Loading…
Reference in New Issue