mirror of
https://github.com/scm-manager/scm-manager.git
synced 2025-11-13 17:05:43 +01:00
fix selenium integration tests and introduce page object pattern
This commit is contained in:
@@ -34,25 +34,27 @@ package sonia.scm.selenium;
|
||||
|
||||
//~--- non-JDK imports --------------------------------------------------------
|
||||
|
||||
import sonia.scm.selenium.page.Pages;
|
||||
import sonia.scm.selenium.page.MainPage;
|
||||
import sonia.scm.selenium.page.LoginPage;
|
||||
import static org.junit.Assert.*;
|
||||
import org.junit.Test;
|
||||
|
||||
/**
|
||||
*
|
||||
* Authentication related selenium integration tests.
|
||||
*
|
||||
* @author Sebastian Sdorra
|
||||
*/
|
||||
public class AuthenticationITCase extends SeleniumTestBase
|
||||
{
|
||||
public class AuthenticationITCase extends SeleniumITCaseBase {
|
||||
|
||||
/**
|
||||
* Method description
|
||||
*
|
||||
*
|
||||
* @throws Exception
|
||||
* Authenticates an user and call logout function.
|
||||
*/
|
||||
@Test
|
||||
public void testAuthentication() throws Exception
|
||||
{
|
||||
login("scmadmin", "scmadmin");
|
||||
logout();
|
||||
public void testAuthentication() {
|
||||
MainPage main = Pages.get(driver, LoginPage.class).login("scmadmin", "scmadmin");
|
||||
assertEquals("scmadmin", main.getUserInfo());
|
||||
main.logout();
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user