Skip to content

Commit

Permalink
KEYCLOAK-4278 Testsuite failures with -Pauth-server-wildfly
Browse files Browse the repository at this point in the history
  • Loading branch information
mstruk committed Mar 14, 2017
1 parent 613f4bb commit df992ae
Show file tree
Hide file tree
Showing 5 changed files with 27 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@

import org.jboss.arquillian.graphene.page.Page;
import org.junit.After;
import org.junit.Before;
import org.junit.Test;
import org.keycloak.representations.idm.RealmRepresentation;
import org.keycloak.representations.idm.UserRepresentation;
Expand All @@ -28,9 +29,10 @@
import org.keycloak.testsuite.auth.page.login.OIDCLogin;
import org.keycloak.testsuite.auth.page.login.VerifyEmail;
import org.keycloak.testsuite.util.MailServerConfiguration;
import org.keycloak.testsuite.util.RealmRepUtil;
import org.keycloak.testsuite.util.SslMailServer;

import java.util.concurrent.TimeUnit;

import static org.junit.Assert.assertEquals;
import static org.keycloak.testsuite.util.MailAssert.assertEmailAndGetUrl;
import static org.keycloak.testsuite.util.URLAssert.assertCurrentUrlStartsWith;
Expand Down Expand Up @@ -77,6 +79,10 @@ public void afterTrustStoreEmailTest() {
SslMailServer.stop();
}

@Before
public void increaseRequestTimeout() {
driver.manage().timeouts().pageLoadTimeout(30, TimeUnit.SECONDS);
}

@Test
public void verifyEmailWithSslEnabled() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@
import javax.mail.internet.MimeMessage;
import java.io.IOException;
import java.util.Collections;
import java.util.concurrent.TimeUnit;

import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertTrue;
Expand Down Expand Up @@ -98,6 +99,11 @@ public void before() {
ApiUtil.createUserAndResetPasswordWithAdminClient(testRealm(), user, "password");
}

@Before
public void increaseRequestTimeout() {
driver.manage().timeouts().pageLoadTimeout(30, TimeUnit.SECONDS);
}

@Test
public void verifyEmailExisting() throws IOException, MessagingException {
loginPage.open();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -174,6 +174,7 @@ public void testLinkAccountWithEmailVerified() {
resetUserPassword(adminClient.realm(bc.consumerRealmName()).users().get(userId), "password", false);

//test
driver.manage().timeouts().pageLoadTimeout(30, TimeUnit.SECONDS);
driver.navigate().to(getAccountUrl(bc.consumerRealmName()));

log.debug("Clicking social " + bc.getIDPAlias());
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@
import java.io.IOException;
import java.util.HashMap;
import java.util.Map;
import java.util.concurrent.TimeUnit;
import java.util.concurrent.atomic.AtomicInteger;

import static org.junit.Assert.assertEquals;
Expand Down Expand Up @@ -104,6 +105,11 @@ public void setup() {
@Rule
public AssertEvents events = new AssertEvents(this);

@Before
public void increaseRequestTimeout() {
driver.manage().timeouts().pageLoadTimeout(30, TimeUnit.SECONDS);
}

@Test
public void resetPasswordLink() throws IOException, MessagingException {
String username = "login-test";
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@

import org.jboss.arquillian.graphene.page.Page;
import org.junit.Assert;
import org.junit.Before;
import org.junit.Rule;
import org.junit.Test;
import org.keycloak.models.UserModel;
Expand All @@ -30,6 +31,7 @@
import javax.mail.MessagingException;
import javax.mail.internet.MimeMessage;
import java.io.IOException;
import java.util.concurrent.TimeUnit;

import static org.junit.Assert.assertEquals;
import org.keycloak.testsuite.ProfileAssume;
Expand All @@ -55,6 +57,11 @@ private void changeUserLocale(String locale) {
ApiUtil.findUserByUsernameId(testRealm(), "login-test").update(user);
}

@Before
public void increaseRequestTimeout() {
driver.manage().timeouts().pageLoadTimeout(30, TimeUnit.SECONDS);
}

@Test
public void restPasswordEmail() throws IOException, MessagingException {
loginPage.open();
Expand Down

0 comments on commit df992ae

Please sign in to comment.