当前位置: 首页>>代码示例>>Java>>正文


Java AutomationContext.getContextTenant方法代码示例

本文整理汇总了Java中org.wso2.carbon.automation.engine.context.AutomationContext.getContextTenant方法的典型用法代码示例。如果您正苦于以下问题:Java AutomationContext.getContextTenant方法的具体用法?Java AutomationContext.getContextTenant怎么用?Java AutomationContext.getContextTenant使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在org.wso2.carbon.automation.engine.context.AutomationContext的用法示例。


在下文中一共展示了AutomationContext.getContextTenant方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: init

import org.wso2.carbon.automation.engine.context.AutomationContext; //导入方法依赖的package包/类
protected void init(TestUserMode userType) throws Exception {
//        dssContext = new AutomationContext("DSS", "dss01", "carbon.supper", "admin");
        dssContext = new AutomationContext(PRODUCT_NAME, userType);
        LoginLogoutClient loginLogoutClient = new LoginLogoutClient(dssContext);
        sessionCookie = loginLogoutClient.login();
        //return the current tenant as the userType(TestUserMode)
        tenantInfo = dssContext.getContextTenant();
        //return the user information initialized with the system
        userInfo = tenantInfo.getContextUser();

    }
 
开发者ID:wso2,项目名称:product-ei,代码行数:12,代码来源:DSSIntegrationTest.java

示例2: init

import org.wso2.carbon.automation.engine.context.AutomationContext; //导入方法依赖的package包/类
/**
 * Initialize the context given a tenant domain and a user.
 *
 * @param tenantName the name of the tenant domain. Should be one of the domains specified in the automation.xml
 * @param userName   The name of the user to be initialized
 * @throws Exception if an error occurs during context initialization
 */
protected void init(String tenantName, String userName) throws Exception {
    axis2Client = new StockQuoteClient();
    DefaultInstance defaultInstance = new DefaultInstance();
    String instanceName = defaultInstance.getDefaultManager(ESBTestConstant.ESB_PRODUCT_GROUP);
    context = new AutomationContext(ESBTestConstant.ESB_PRODUCT_GROUP, instanceName, tenantName, userName);
    contextUrls = context.getContextUrls();
    sessionCookie = login(context);
    esbUtils = new ESBTestCaseUtils();
    tenantInfo = context.getContextTenant();
    userInfo = tenantInfo.getContextUser();
}
 
开发者ID:wso2,项目名称:product-ei,代码行数:19,代码来源:ESBIntegrationTest.java

示例3: init

import org.wso2.carbon.automation.engine.context.AutomationContext; //导入方法依赖的package包/类
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);
    }
 
开发者ID:wso2,项目名称:product-es,代码行数:16,代码来源:ESIntegrationTest.java

示例4: setInfoRolesAndUsers

import org.wso2.carbon.automation.engine.context.AutomationContext; //导入方法依赖的package包/类
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);


    }
 
开发者ID:wso2,项目名称:product-es,代码行数:14,代码来源:RegistryUserCreator.java

示例5: buildTenantDetails

import org.wso2.carbon.automation.engine.context.AutomationContext; //导入方法依赖的package包/类
protected void buildTenantDetails(TestUserMode userMode) throws Exception {
    AutomationContext automationContext = new AutomationContext(PRODUCT_GROUP_NAME, userMode);
    tenantDetails = automationContext.getContextTenant();
}
 
开发者ID:wso2,项目名称:product-es,代码行数:5,代码来源:BaseUITestCase.java


注:本文中的org.wso2.carbon.automation.engine.context.AutomationContext.getContextTenant方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。