use of com.hack23.cia.web.impl.ui.application.views.common.pagelinks.api.PageModeMenuCommand in project cia by Hack23.
the class AdminRoleSystemTest method siteAdminUseraccountTest.
/**
* Site admin useraccount test.
*
* @throws Exception
* the exception
*/
@Test
public void siteAdminUseraccountTest() throws Exception {
final WebDriver driver = getWebDriver();
assertNotNull(NO_WEBDRIVER_EXIST_FOR_BROWSER + browser, driver);
final UserPageVisit userPageVisit = new UserPageVisit(driver, browser);
loginAsAdmin(userPageVisit);
userPageVisit.visitDirectPage(new PageModeMenuCommand(AdminViews.ADMIN_USERACCOUNT_VIEW_NAME, ""));
assertTrue("Expect content", userPageVisit.checkHtmlBodyContainsText("Useraccount"));
clickFirstRowInGrid(userPageVisit);
userPageVisit.validatePage(new PageModeMenuCommand(AdminViews.ADMIN_USERACCOUNT_VIEW_NAME, ""));
}
use of com.hack23.cia.web.impl.ui.application.views.common.pagelinks.api.PageModeMenuCommand in project cia by Hack23.
the class AdminRoleSystemTest method visitAdminDataSummaryViewRemoveDocumentsTest.
/**
* Visit admin data summary view remove documents test.
*
* @throws Exception
* the exception
*/
@Test
public void visitAdminDataSummaryViewRemoveDocumentsTest() throws Exception {
final WebDriver driver = getWebDriver();
assertNotNull(NO_WEBDRIVER_EXIST_FOR_BROWSER + browser, driver);
final UserPageVisit userPageVisit = new UserPageVisit(driver, browser);
loginAsAdmin(userPageVisit);
userPageVisit.visitDirectPage(new PageModeMenuCommand(AdminViews.ADMIN_DATA_SUMMARY_VIEW_NAME, ""));
final WebElement removeDocumentsButton = userPageVisit.findButton("Remove Documents");
assertNotNull("Expect to find a Button", removeDocumentsButton);
// userPageVisit.performClickAction(removeDocumentsButton);
}
use of com.hack23.cia.web.impl.ui.application.views.common.pagelinks.api.PageModeMenuCommand in project cia by Hack23.
the class AdminRoleSystemTest method visitAdminDataSummaryViewRefreshViewsTest.
/**
* Visit admin data summary view refresh views test.
*
* @throws Exception
* the exception
*/
@Test
public void visitAdminDataSummaryViewRefreshViewsTest() throws Exception {
final WebDriver driver = getWebDriver();
assertNotNull(NO_WEBDRIVER_EXIST_FOR_BROWSER + browser, driver);
final UserPageVisit userPageVisit = new UserPageVisit(driver, browser);
loginAsAdmin(userPageVisit);
userPageVisit.visitDirectPage(new PageModeMenuCommand(AdminViews.ADMIN_DATA_SUMMARY_VIEW_NAME, ""));
final WebElement refreshViewsButton = userPageVisit.findButton("Refresh Views");
assertNotNull("Expect to find a Refresh Views Button", refreshViewsButton);
userPageVisit.performClickAction(refreshViewsButton);
}
use of com.hack23.cia.web.impl.ui.application.views.common.pagelinks.api.PageModeMenuCommand in project cia by Hack23.
the class AdminRoleSystemTest method visitAdminDataSummaryViewRemovePoliticianTest.
/**
* Visit admin data summary view remove politician test.
*
* @throws Exception
* the exception
*/
@Test
public void visitAdminDataSummaryViewRemovePoliticianTest() throws Exception {
final WebDriver driver = getWebDriver();
assertNotNull(NO_WEBDRIVER_EXIST_FOR_BROWSER + browser, driver);
final UserPageVisit userPageVisit = new UserPageVisit(driver, browser);
loginAsAdmin(userPageVisit);
userPageVisit.visitDirectPage(new PageModeMenuCommand(AdminViews.ADMIN_DATA_SUMMARY_VIEW_NAME, ""));
final WebElement removePoliticiansButton = userPageVisit.findButton("Remove Politicians");
assertNotNull("Expect to find a Button", removePoliticiansButton);
// userPageVisit.performClickAction(removePoliticiansButton);
}
use of com.hack23.cia.web.impl.ui.application.views.common.pagelinks.api.PageModeMenuCommand in project cia by Hack23.
the class AdminRoleSystemTest method siteAdminAgentOperationTest.
/**
* Site admin test.
*
* @throws Exception
* the exception
*/
@Test
public void siteAdminAgentOperationTest() throws Exception {
final WebDriver driver = getWebDriver();
assertNotNull(NO_WEBDRIVER_EXIST_FOR_BROWSER + browser, driver);
final UserPageVisit userPageVisit = new UserPageVisit(driver, browser);
loginAsAdmin(userPageVisit);
userPageVisit.visitDirectPage(new PageModeMenuCommand(AdminViews.ADMIN_AGENT_OPERATIONVIEW_NAME, ""));
userPageVisit.verifyViewActions(new ViewAction[] { ViewAction.VISIT_MAIN_VIEW });
final WebElement importWorldBankDataButton = userPageVisit.findButton("Start IMPORT MODEL_EXTERNAL_WORLDBANK");
assertNotNull("Start IMPORT MODEL_EXTERNAL_WORLDBANK Button", importWorldBankDataButton);
final WebElement importRiksdagenDataButton = userPageVisit.findButton("Start IMPORT MODEL_EXTERNAL_RIKSDAGEN");
assertNotNull("Start IMPORT MODEL_EXTERNAL_RIKSDAGEN Button", importRiksdagenDataButton);
userPageVisit.performClickAction(importRiksdagenDataButton);
}
Aggregations