public abstract class DSUIIntegrationTest extends DSIntegrationTest
| Modifier and Type | Field and Description |
|---|---|
protected String |
resourcePath |
userMode| Constructor and Description |
|---|
DSUIIntegrationTest() |
DSUIIntegrationTest(org.wso2.carbon.automation.engine.context.TestUserMode userMode) |
| Modifier and Type | Method and Description |
|---|---|
void |
addDashBoard(String dashBoardTitle,
String description)
Add dashboard to DashboardServer
|
void |
addRole(String roleName)
Add dashboard to DashboardServer
|
void |
addUser(String username,
String password,
String retypePassword)
Add dashboard to DashboardServer
|
void |
assignRoleToUser(String[] userNames)
Assign roles for users
|
void |
dsUITestTearDown()
final method for each test classes
|
String |
generateAddGadgetScript(String[][] mappings)
Get JS script to simulate adding gadgets to the page
|
DSWebDriver |
getDriver()
This method returns the web driver instance
|
org.openqa.selenium.support.ui.WebDriverWait |
getWebDriverWait()
This method returns the we driver wait instance
|
boolean |
isResourceExist(String resourcePath)
This method will check the resource is exist or not in registry
|
void |
login(String userName,
String pwd)
To login to Dashboard server
|
void |
loginToAdminConsole(String userName,
String pwd)
To login to admin console DashBoard server
|
void |
logout()
To logout from Dashboard server
|
void |
logoutFromAdminConsole()
To logout from admin console dashboard server
|
void |
popWindow()
Switch to the parent window (while is remembered previously) from a child window
|
void |
pushWindow()
Switch to a child window while remembering the parent window
|
getBackEndUrl, getBaseUrl, getCurrentPassword, getCurrentTenantInfo, getCurrentUserInfo, getCurrentUsername, getMaxWaitTime, getResourceLocation, getServiceUrlHttp, getServiceUrlHttps, isTenantprotected String resourcePath
public DSUIIntegrationTest()
public DSUIIntegrationTest(org.wso2.carbon.automation.engine.context.TestUserMode userMode)
public String generateAddGadgetScript(String[][] mappings)
mappings - array of gadget mappings in { gadget id, target id} formatpublic void pushWindow()
throws MalformedURLException,
XPathExpressionException
public void popWindow()
throws MalformedURLException,
XPathExpressionException
public void login(String userName, String pwd) throws Exception
userName - user namepwd - passwordjavax.xml.xpath.XPathExpressionException,InterruptedExceptionExceptionpublic void logout()
throws Exception
XPathExpressionExceptionExceptionpublic void loginToAdminConsole(String userName, String pwd) throws Exception
userName - user namepwd - passwordXPathExpressionExceptionExceptionpublic void logoutFromAdminConsole()
throws Exception
Exceptionpublic void addDashBoard(String dashBoardTitle, String description) throws Exception
dashBoardTitle - the title of a dashboarddescription - the description about dashboardExceptionpublic void addUser(String username, String password, String retypePassword) throws Exception
username - username of userpassword - password of userretypePassword - retype password of userExceptionpublic void addRole(String roleName) throws Exception
roleName - name of roleExceptionpublic void assignRoleToUser(String[] userNames) throws Exception
userNames - array fo userNamesExceptionpublic DSWebDriver getDriver() throws MalformedURLException, XPathExpressionException
MalformedURLExceptionXPathExpressionExceptionpublic org.openqa.selenium.support.ui.WebDriverWait getWebDriverWait()
throws MalformedURLException,
XPathExpressionException
MalformedURLExceptionXPathExpressionExceptionpublic void dsUITestTearDown()
throws Exception
Exceptionpublic boolean isResourceExist(String resourcePath)
resourcePath - - the path of resourceCopyright © 2015 WSO2 Inc. All rights reserved.