Fix tests
This commit is contained in:
parent
a279ff3d7f
commit
2ec143a3ba
2 changed files with 6 additions and 6 deletions
|
@ -205,7 +205,7 @@ public class CustomFlowTest {
|
|||
PassThroughClientAuthenticator.clientId = "unknown";
|
||||
OAuthClient.AccessTokenResponse response = oauth.doGrantAccessTokenRequest("password", "test-user", "password");
|
||||
assertEquals(400, response.getStatusCode());
|
||||
assertEquals("invalid_client", response.getError());
|
||||
assertEquals("unauthorized_client", response.getError());
|
||||
|
||||
events.expectLogin()
|
||||
.client((String) null)
|
||||
|
@ -214,7 +214,7 @@ public class CustomFlowTest {
|
|||
.removeDetail(Details.CODE_ID)
|
||||
.removeDetail(Details.REDIRECT_URI)
|
||||
.removeDetail(Details.CONSENT)
|
||||
.error(Errors.CLIENT_NOT_FOUND)
|
||||
.error(Errors.INVALID_CLIENT_CREDENTIALS)
|
||||
.assertEvent();
|
||||
}
|
||||
|
||||
|
|
|
@ -212,7 +212,7 @@ public class ClientAuthSignedJWTTest {
|
|||
HttpResponse resp = sendRequest(oauth.getServiceAccountUrl(), parameters);
|
||||
OAuthClient.AccessTokenResponse response = new OAuthClient.AccessTokenResponse(resp);
|
||||
|
||||
assertError(response, null, "invalid_client", Errors.INVALID_CLIENT);
|
||||
assertError(response, null, "unauthorized_client", Errors.INVALID_CLIENT_CREDENTIALS);
|
||||
}
|
||||
|
||||
@Test
|
||||
|
@ -224,7 +224,7 @@ public class ClientAuthSignedJWTTest {
|
|||
HttpResponse resp = sendRequest(oauth.getServiceAccountUrl(), parameters);
|
||||
OAuthClient.AccessTokenResponse response = new OAuthClient.AccessTokenResponse(resp);
|
||||
|
||||
assertError(response, null, "invalid_client", Errors.INVALID_CLIENT);
|
||||
assertError(response, null, "unauthorized_client", Errors.INVALID_CLIENT_CREDENTIALS);
|
||||
}
|
||||
|
||||
@Test
|
||||
|
@ -236,7 +236,7 @@ public class ClientAuthSignedJWTTest {
|
|||
HttpResponse resp = sendRequest(oauth.getServiceAccountUrl(), parameters);
|
||||
OAuthClient.AccessTokenResponse response = new OAuthClient.AccessTokenResponse(resp);
|
||||
|
||||
assertError(response, null, "invalid_client", Errors.INVALID_CLIENT_CREDENTIALS);
|
||||
assertError(response, null, "unauthorized_client", Errors.INVALID_CLIENT_CREDENTIALS);
|
||||
}
|
||||
|
||||
@Test
|
||||
|
@ -268,7 +268,7 @@ public class ClientAuthSignedJWTTest {
|
|||
HttpResponse resp = sendRequest(oauth.getServiceAccountUrl(), parameters);
|
||||
OAuthClient.AccessTokenResponse response = new OAuthClient.AccessTokenResponse(resp);
|
||||
|
||||
assertError(response, "unknown-client", "invalid_client", Errors.CLIENT_NOT_FOUND);
|
||||
assertError(response, "unknown-client", "unauthorized_client", Errors.INVALID_CLIENT_CREDENTIALS);
|
||||
}
|
||||
|
||||
@Test
|
||||
|
|
Loading…
Reference in a new issue