protected void init() throws IOException, XMLStreamException, XPathExpressionException { automationContext = new AutomationContext("EMM", "emm001", TestUserMode.SUPER_TENANT_ADMIN); }
protected void init() throws XPathExpressionException { automationContext = new AutomationContext(); }
protected void init() throws Exception { automationContext = new AutomationContext("DSS", "dss001", TestUserMode.SUPER_TENANT_ADMIN); }
private TestConfigurationProvider() { try { context = new AutomationContext(); } catch (XPathExpressionException e) { log.error("Loading Automation Configuration failed", e); } }
protected void init(TestUserMode userMode) throws XPathExpressionException/*, AutomationUtilException*/ { automationContext = new AutomationContext(CarbonIntegrationConstants.PRODUCT_GROUP, userMode); contextUrls = automationContext.getContextUrls(); /*loginLogoutClient = new LoginLogoutClient(automationContext); sessionCookie = loginLogoutClient.login(); backendURL = automationContext.getContextUrls().getBackEndUrl(); userInfo = automationContext.getContextTenant().getContextUser(); } protected String getServiceUrl(String serviceName) throws XPathExpressionException { return automationContext.getContextUrls().getServiceUrl() + "/" + serviceName;*/ }
protected void buildTenantDetails(TestUserMode userMode) throws Exception { AutomationContext automationContext = new AutomationContext(PRODUCT_GROUP_NAME, userMode); tenantDetails = automationContext.getContextTenant(); } }
@BeforeClass(alwaysRun = true) public void init() throws XPathExpressionException, AutomationFrameworkException { // to start the server from a different port offset serverPropertyMap.put("-DportOffset", "1"); // start with OSGI component service serverPropertyMap.put("-DosgiConsole", Integer.toString(telnetPort)); AutomationContext autoCtx = new AutomationContext(); CarbonTestServerManager server = new CarbonTestServerManager(autoCtx, System.getProperty("carbon.zip"), serverPropertyMap); manager.startServers(server); }
protected void initPublisher(String productGroupName, String instanceName, TestUserMode userMode, String userKey) throws XPathExpressionException { automationContext = new AutomationContext(productGroupName, instanceName, userMode); backendURL = automationContext.getContextUrls().getBackEndUrl(); }
/** * Initialize the base test by initializing the automation context. * * @param userMode The testing user mode * @throws XPathExpressionException */ protected void init(TestUserMode userMode) throws XPathExpressionException { // org.apache.xerces.dom.ParentNode.nodeListItem which is used in AutomationContext // does not guarantee thread safety. // Hence to allow tests to run in parallel, this initialization should be synchronized synchronized (this.getClass()) { automationContext = new AutomationContext("MB", userMode); backendURL = automationContext.getContextUrls().getBackEndUrl(); } }
public UserPopulator(String productGroupName, String instanceName) throws XPathExpressionException { this.automationContext = new AutomationContext(productGroupName, instanceName, TestUserMode.SUPER_TENANT_ADMIN); this.tenantList = getTenantList(); this.rolesList = getRolesList(); }
protected void initPublisher(String productGroupName, String instanceName, TestUserMode userMode, String userKey) throws XPathExpressionException { automationContext = new AutomationContext(productGroupName, instanceName, userMode); backendURL = automationContext.getContextUrls().getBackEndUrl(); }
protected void init(TestUserMode testUserMode) throws Exception { storeContext = new AutomationContext("es", "store", testUserMode); publisherContext = new AutomationContext("es", "publisher", testUserMode); automationContext = new AutomationContext("es",testUserMode); loginLogoutClient = new LoginLogoutClient(automationContext); sessionCookie = loginLogoutClient.login(); backendURL = automationContext.getContextUrls().getBackEndUrl(); webAppURL = automationContext.getContextUrls().getWebAppURL(); userInfo = automationContext.getContextTenant().getContextUser(); }
protected void init(TestUserMode userType) throws Exception { esContext = new AutomationContext("ES", userType); automationContext = esContext; LoginLogoutClient loginLogoutClient = new LoginLogoutClient(esContext); sessionCookie = loginLogoutClient.login(); //return the current tenant as the userType(TestUserMode) tenantInfo = esContext.getContextTenant(); //return the user information initialized with the system userInfo = automationContext.getContextTenant().getContextUser(); backendURL = automationContext.getContextUrls().getBackEndUrl(); webAppURL = automationContext.getContextUrls().getWebAppURL(); storeContext = new AutomationContext("ES", "store", userType); publisherContext = new AutomationContext("ES", "publisher", userType); } protected void init(String tenantKey, String userKey) throws Exception {
protected void init(String tenantKey, String userKey) throws Exception { esContext = new AutomationContext(ESIntegrationTestConstants.ES_PRODUCT_NAME, "es002", tenantKey, userKey); LoginLogoutClient loginLogoutClient = new LoginLogoutClient(esContext); sessionCookie = loginLogoutClient.login(); //return the current tenant as the userType(TestUserMode) tenantInfo = esContext.getContextTenant(); //return the user information initialized with the system userInfo = tenantInfo.getContextUser(); }
/** * Initializes the automation context, login client, session cookie and the backend url by {@link org.wso2.carbon * .automation.engine.context.TestUserMode#SUPER_TENANT_ADMIN}. * * @throws AutomationUtilException * @throws MalformedURLException * @throws XPathExpressionException */ protected void init() throws AutomationUtilException, IOException, XPathExpressionException { mbServer = new AutomationContext("MB", TestUserMode.SUPER_TENANT_ADMIN); loginLogoutClient = new LoginLogoutClient(mbServer); sessionCookie = loginLogoutClient.login(); backendURL = mbServer.getContextUrls().getBackEndUrl(); this.driver = BrowserManager.getWebDriver(); }
protected void init(TestUserMode testUserMode) throws Exception { bpsServer = new AutomationContext("BPS", testUserMode); loginLogoutClient = new LoginLogoutClient(bpsServer); sessionCookie = loginLogoutClient.login(); backEndUrl = bpsServer.getContextUrls().getBackEndUrl(); serviceUrl = bpsServer.getContextUrls().getServiceUrl(); bpelUploaderClient = new BpelUploaderClient(backEndUrl, sessionCookie); humanTaskUploaderClient = new HumanTaskUploaderClient(backEndUrl, sessionCookie); bpmnUploaderClient = new BPMNUploaderClient(backEndUrl, sessionCookie); }
protected void init(String domainKey, String userKey) throws Exception { bpsServer = new AutomationContext("BPS", "bpsServerInstance0001", domainKey, userKey); loginLogoutClient = new LoginLogoutClient(bpsServer); sessionCookie = loginLogoutClient.login(); backEndUrl = bpsServer.getContextUrls().getBackEndUrl(); serviceUrl = bpsServer.getContextUrls().getServiceUrl(); bpelUploaderClient = new BpelUploaderClient(backEndUrl, sessionCookie); humanTaskUploaderClient = new HumanTaskUploaderClient(backEndUrl, sessionCookie); bpmnUploaderClient = new BPMNUploaderClient(backEndUrl, sessionCookie); }
protected void init() throws Exception { bpsServer = new AutomationContext("BPS", TestUserMode.SUPER_TENANT_ADMIN); loginLogoutClient = new LoginLogoutClient(bpsServer); sessionCookie = loginLogoutClient.login(); backEndUrl = bpsServer.getContextUrls().getBackEndUrl(); serviceUrl = bpsServer.getContextUrls().getServiceUrl(); bpelUploaderClient = new BpelUploaderClient(backEndUrl, sessionCookie); humanTaskUploaderClient = new HumanTaskUploaderClient(backEndUrl, sessionCookie); bpmnUploaderClient = new BPMNUploaderClient(backEndUrl, sessionCookie); }
@BeforeSuite(alwaysRun = true) public void initialize() throws XPathExpressionException, AxisFault { AutomationContext autoContext = new AutomationContext(); logViewerClient = new LogViewerClient(autoContext.getContextUrls().getBackEndUrl(), autoContext.getSuperTenant().getTenantAdmin().getUserName(), autoContext.getSuperTenant().getTenantAdmin().getPassword()); }
public void setInfoRolesAndUsers(String adminUserKey) throws LoginAuthenticationExceptionException, RemoteException, XPathExpressionException { //todo - // FrameworkProperties isProperties = FrameworkFactory.getFrameworkProperties(ProductConstant.IS_SERVER_NAME); AutomationContext isContext = new AutomationContext("IS", "is", "carbon.supper", adminUserKey); Tenant userAdminDetails = isContext.getContextTenant(); sessionCookie = login(userAdminDetails.getContextUser().getUserName(), userAdminDetails.getContextUser().getPassword(), isContext.getContextUrls().getBackEndUrl()); userAdminStub = new UserManagementClient(isContext.getContextUrls().getBackEndUrl(), sessionCookie); }