Skip to content

Commit 9f9ee69

Browse files
committed
one more test is ready
1 parent 8a4d8a5 commit 9f9ee69

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

Wissance.Authorization/Wissance.Authorization.Tests/OpenId/TestKeyCloakOpenIdAuthenticator.cs

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -68,10 +68,12 @@ public void TestGetUserInfo(string userName, string password, string scope)
6868
}
6969

7070
[Theory]
71-
[InlineData(TestUser, TestPassword, TestScope)]
72-
public void TestTokenRefresh(string userName, string password, string scope)
71+
[InlineData(TestUser, TestPassword, TestScope, true)]
72+
[InlineData(TestUser, TestPassword, TestScope, false)]
73+
public void TestTokenRefresh(string userName, string password, string scope, bool isPrivate)
7374
{
74-
IOpenIdAuthenticator authenticator = new KeyCloakOpenIdAuthenticator(_testPrivateKeyCloakConfig, new LoggerFactory());
75+
KeyCloakServerConfig config = isPrivate ? _testPrivateKeyCloakConfig : _testPublicKeyCloakConfig;
76+
IOpenIdAuthenticator authenticator = new KeyCloakOpenIdAuthenticator(config, new LoggerFactory());
7577
TokenInfo token = GetToken(authenticator, userName, password, scope);
7678
Assert.NotNull(token);
7779
Task<TokenInfo> refreshTokenTask = authenticator.RefreshTokenAsync(token.RefreshToken);

0 commit comments

Comments
 (0)