use of sample.pages.LoginPage in project spring-session by spring-projects.
the class HttpRedisJsonTest method createAttribute.
@Test
public void createAttribute() {
LoginPage login = HomePage.go(this.driver, LoginPage.class);
HomePage home = login.form().login(HomePage.class);
// @formatter:off
home = home.form().attributeName("Demo Key").attributeValue("Demo Value").submit(HomePage.class);
// @formatter:on
List<Attribute> attributes = home.attributes();
assertThat(attributes).extracting("attributeName").contains("Demo Key");
assertThat(attributes).extracting("attributeValue").contains("Demo Value");
}
use of sample.pages.LoginPage in project spring-session by spring-projects.
the class HttpRedisJsonTest method goHomeRedirectLoginPage.
@Test
public void goHomeRedirectLoginPage() {
LoginPage login = HomePage.go(this.driver, LoginPage.class);
login.assertAt();
}
use of sample.pages.LoginPage in project spring-session by spring-projects.
the class BootTests method login.
@Test
public void login() {
LoginPage login = HomePage.go(this.driver);
HomePage home = login.form().login(HomePage.class);
home.assertAt();
home.containCookie("SESSION");
home.doesNotContainCookie("JSESSIONID");
}
use of sample.pages.LoginPage in project spring-session by spring-projects.
the class SecurityTests method loggedOutUserSentToLoginPage.
@Test
public void loggedOutUserSentToLoginPage() {
LoginPage loginPage = LoginPage.go(this.driver);
HomePage homePage = loginPage.login("user", "password");
homePage.logout();
HomePage backHomePage = HomePage.go(this.driver);
LoginPage backLoginPage = backHomePage.unauthenticated();
backLoginPage.assertAt();
}
use of sample.pages.LoginPage in project spring-session by spring-projects.
the class SecurityTests method logOutSuccess.
@Test
public void logOutSuccess() {
LoginPage loginPage = LoginPage.go(this.driver);
HomePage homePage = loginPage.login("user", "password");
LoginPage successLogoutPage = homePage.logout();
successLogoutPage.assertAt();
}
Aggregations