KEYCLOAK-4536 Add test to check behavior with file redirect URI (#4291)

This commit is contained in:
Stian Thorgersen 2017-07-05 09:08:13 +02:00 committed by GitHub
parent 9a9f4137e5
commit eba8dac47d

View file

@ -142,6 +142,14 @@ public class OAuthRedirectUriTest extends AbstractKeycloakTest {
Assert.assertEquals("Invalid parameter: redirect_uri", errorPage.getError());
}
@Test
public void testFileUri() throws IOException {
oauth.redirectUri("file://test");
oauth.openLoginForm();
Assert.assertTrue(errorPage.isCurrent());
Assert.assertEquals("Invalid parameter: redirect_uri", errorPage.getError());
}
@Test
public void testNoParamMultipleValidUris() throws IOException {
ClientManager.realm(adminClient.realm("test")).clientId("test-app").addRedirectUris("http://localhost:8180/app2");