Skip to content

Commit

Permalink
KEYCLOAK-1823
Browse files Browse the repository at this point in the history
Annoying behaviour of validations in user registration form
  • Loading branch information
stianst committed Oct 13, 2015
1 parent 85a886d commit 07c3772
Showing 1 changed file with 8 additions and 4 deletions.
Expand Up @@ -194,16 +194,20 @@ public void registerUserMissingUsername() {
}

@Test
@Ignore
public void registerUserMissingUsernameAndInvalidEmail() {
public void registerUserManyErrors() {
loginPage.open();
loginPage.clickRegister();
registerPage.assertCurrent();

registerPage.register("firstName", "lastName", "registerUserInvalidEmail", null, "password", "password");
registerPage.register(null, null, null, "registerUserManyErrors", null, "password");

registerPage.assertCurrent();
assertEquals("Please specify username.", registerPage.getError());

System.out.println(registerPage.getError());

assertEquals("Please specify first name.\n" +
"Please specify last name.\n" +
"Please specify email.", registerPage.getError());

events.expectRegister(null, "registerUserMissingUsername@email")
.removeDetail(Details.USERNAME)
Expand Down

0 comments on commit 07c3772

Please sign in to comment.