Skip to content

Commit 05afae7

Browse files
committed
Avoid downloading OIDC config
1 parent 3b52f6b commit 05afae7

File tree

1 file changed

+12
-4
lines changed

1 file changed

+12
-4
lines changed

tests/Microsoft.Owin.Security.Tests/OpenIdConnect/OpenIdConnectMiddlewareTests.cs

Lines changed: 12 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -27,11 +27,15 @@ public async Task ChallengeIncludesPkceIfRequested(bool include)
2727
{
2828
var options = new OpenIdConnectAuthenticationOptions()
2929
{
30-
Authority = "https://demo.identityserver.io",
30+
Authority = "https://authserver/",
3131
ClientId = "Test Client Id",
3232
ClientSecret = "Test Client Secret",
3333
UsePkce = include,
34-
ResponseType = OpenIdConnectResponseType.Code
34+
ResponseType = OpenIdConnectResponseType.Code,
35+
Configuration = new OpenIdConnectConfiguration()
36+
{
37+
AuthorizationEndpoint = "https://authserver/auth"
38+
}
3539
};
3640
var server = CreateServer(
3741
app => app.UseOpenIdConnectAuthentication(options),
@@ -67,11 +71,15 @@ public async Task ChallengeDoesNotIncludePkceForOtherResponseTypes(string respon
6771
{
6872
var options = new OpenIdConnectAuthenticationOptions()
6973
{
70-
Authority = "https://demo.identityserver.io",
74+
Authority = "https://authserver/",
7175
ClientId = "Test Client Id",
7276
ClientSecret = "Test Client Secret",
7377
UsePkce = true,
74-
ResponseType = responseType
78+
ResponseType = responseType,
79+
Configuration = new OpenIdConnectConfiguration()
80+
{
81+
AuthorizationEndpoint = "https://authserver/auth"
82+
}
7583
};
7684
var server = CreateServer(
7785
app => app.UseOpenIdConnectAuthentication(options),

0 commit comments

Comments
 (0)