KEYCLOAK-8522: Remove broker tests covered in new testsuite.
This commit is contained in:
parent
05005a1791
commit
b64f30c9d7
4 changed files with 0 additions and 96 deletions
|
@ -97,46 +97,6 @@ public abstract class AbstractKeycloakIdentityProviderTest extends AbstractIdent
|
|||
}
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testTemporarilyDisabledUser() {
|
||||
KeycloakSession session = brokerServerRule.startSession();
|
||||
setUpdateProfileFirstLogin(session.realms().getRealmByName("realm-with-broker"), IdentityProviderRepresentation.UPFLM_OFF);
|
||||
brokerServerRule.stopSession(session, true);
|
||||
|
||||
driver.navigate().to("http://localhost:8081/test-app");
|
||||
loginPage.clickSocial(getProviderId());
|
||||
loginPage.login("test-user", "password");
|
||||
driver.navigate().to("http://localhost:8081/test-app/logout");
|
||||
|
||||
try {
|
||||
session = brokerServerRule.startSession();
|
||||
RealmModel brokerRealm = session.realms().getRealmByName("realm-with-broker");
|
||||
brokerRealm.setBruteForceProtected(true);
|
||||
brokerRealm.setFailureFactor(2);
|
||||
brokerServerRule.stopSession(session, true);
|
||||
|
||||
driver.navigate().to("http://localhost:8081/test-app");
|
||||
loginPage.login("test-user", "fail");
|
||||
loginPage.login("test-user", "fail");
|
||||
|
||||
driver.navigate().to("http://localhost:8081/test-app");
|
||||
|
||||
assertTrue(driver.getCurrentUrl().startsWith("http://localhost:8081/auth/realms/realm-with-broker/protocol/openid-connect/auth"));
|
||||
|
||||
loginPage.clickSocial(getProviderId());
|
||||
loginPage.login("test-user", "password");
|
||||
|
||||
assertTrue(errorPage.isCurrent());
|
||||
assertEquals("Account is disabled, contact admin.", errorPage.getError());
|
||||
} finally {
|
||||
session = brokerServerRule.startSession();
|
||||
RealmModel brokerRealm = session.realms().getRealmByName("realm-with-broker");
|
||||
brokerRealm.setBruteForceProtected(false);
|
||||
brokerRealm.setFailureFactor(0);
|
||||
brokerServerRule.stopSession(session, true);
|
||||
}
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testSuccessfulAuthenticationUpdateProfileOnMissing_nothingMissing() {
|
||||
IdentityProviderModel identityProviderModel = getIdentityProviderModel();
|
||||
|
@ -392,14 +352,6 @@ public abstract class AbstractKeycloakIdentityProviderTest extends AbstractIdent
|
|||
}
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testProviderOnLoginPage() {
|
||||
// Provider button is available on login page
|
||||
this.driver.navigate().to("http://localhost:8081/test-app/");
|
||||
assertTrue(this.driver.getCurrentUrl().startsWith("http://localhost:8081/auth/realms/realm-with-broker/protocol/openid-connect/auth"));
|
||||
loginPage.findSocialButton(getProviderId());
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testAccountManagementLinkIdentity() {
|
||||
// Login as pedroigor to account management
|
||||
|
@ -484,16 +436,6 @@ public abstract class AbstractKeycloakIdentityProviderTest extends AbstractIdent
|
|||
assertEquals("Federated identity returned by " + getProviderId() + " is already linked to another user.", accountFederatedIdentityPage.getError());
|
||||
}
|
||||
|
||||
|
||||
@Test(expected = NoSuchElementException.class)
|
||||
public void testIdentityProviderNotAllowed() {
|
||||
this.driver.navigate().to("http://localhost:8081/test-app/");
|
||||
|
||||
assertTrue(this.driver.getCurrentUrl().startsWith("http://localhost:8081/auth/realms/realm-with-broker/protocol/openid-connect/auth"));
|
||||
|
||||
driver.findElement(By.className("model-oidc-idp"));
|
||||
}
|
||||
|
||||
protected void configureClientRetrieveToken(String clientId) {
|
||||
RealmModel realm = getRealm();
|
||||
RoleModel readTokenRole = realm.getClientByClientId(Constants.BROKER_SERVICE_CLIENT_ID).getRole(Constants.READ_TOKEN_ROLE);
|
||||
|
|
|
@ -182,13 +182,6 @@ public class OIDCBrokerUserPropertyTest extends AbstractKeycloakIdentityProvider
|
|||
// ignore
|
||||
}
|
||||
|
||||
@Override
|
||||
@Test
|
||||
@Ignore
|
||||
public void testProviderOnLoginPage() {
|
||||
// ignore
|
||||
}
|
||||
|
||||
@Override
|
||||
@Test
|
||||
@Ignore
|
||||
|
@ -203,13 +196,6 @@ public class OIDCBrokerUserPropertyTest extends AbstractKeycloakIdentityProvider
|
|||
// ignore
|
||||
}
|
||||
|
||||
@Override
|
||||
@Test
|
||||
@Ignore
|
||||
public void testIdentityProviderNotAllowed() {
|
||||
// ignore
|
||||
}
|
||||
|
||||
@Override
|
||||
@Test
|
||||
@Ignore
|
||||
|
|
|
@ -110,21 +110,11 @@ public class OIDCKeyCloakServerBrokerBasicTest extends AbstractKeycloakIdentityP
|
|||
return "kc-oidc-idp";
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testSuccessfulAuthentication() {
|
||||
super.testSuccessfulAuthentication();
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testDisabledUser() throws Exception {
|
||||
super.testDisabledUser();
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testTemporarilyDisabledUser() {
|
||||
super.testTemporarilyDisabledUser();
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testLogoutWorksWithTokenTimeout() {
|
||||
try (Keycloak keycloak = Keycloak.getInstance("http://localhost:8081/auth", "master", "admin", "admin", org.keycloak.models.Constants.ADMIN_CLI_CLIENT_ID)) {
|
||||
|
|
|
@ -171,13 +171,6 @@ public class SAMLBrokerUserPropertyTest extends AbstractKeycloakIdentityProvider
|
|||
// ignore
|
||||
}
|
||||
|
||||
@Override
|
||||
@Test
|
||||
@Ignore
|
||||
public void testProviderOnLoginPage() {
|
||||
// ignore
|
||||
}
|
||||
|
||||
@Override
|
||||
@Test
|
||||
@Ignore
|
||||
|
@ -192,13 +185,6 @@ public class SAMLBrokerUserPropertyTest extends AbstractKeycloakIdentityProvider
|
|||
// ignore
|
||||
}
|
||||
|
||||
@Override
|
||||
@Test
|
||||
@Ignore
|
||||
public void testIdentityProviderNotAllowed() {
|
||||
// ignore
|
||||
}
|
||||
|
||||
@Override
|
||||
@Test
|
||||
@Ignore
|
||||
|
|
Loading…
Reference in a new issue