mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-08-07 17:49:17 +00:00
Merged V3.0 to HEAD
11410: Activity Service - iBatis mapping files for MS SQL Server (using AlfrescoSQLServerDialect) Can be Enterprised when dual build is set up 11414: Fix for missing servlet reference in repo web.xml 11415: Activity Service - iBatis mapping files for new Oracle dialects (using AlfrescoOracle10gDialect or AlfrescoOracle9iDialect) Can be Entperprised when dual build is up 11424: Remove conflicting java mail libraries. NOTE: Might affect 'CMIS web service implementation' 11426: Activity Service - use lower-case columns 11428: ETHREEOH-300: Site contributor can not delete his own blog posts 11431: Removed tutorial from Guest home 11432: ETHREEOH-198: SiteService is not MT enabled 11440: Close all ScrollableResults in try{} finally{} 11442: Fix for ETHREEOH-268, ETHREEOH-269, ETHREEOH-431, ETHREEOH-438, ETHREEOH-456, ETHREEOH-468, ETHREEOH-532 11443: Update to JSF client Help URL 11444: Build fix 11447: MT - fix ETHREEOH-530 11448: Fix for ETHREEOH-424: Edit Web Content: dojo.data.fromrfc3339 is not a function 11449: Fix for ETHREEOH-218: DM forms should be disabled git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@12427 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
@@ -85,16 +85,20 @@ public class MultiTDemoTest extends TestCase
|
||||
private TenantService tenantService;
|
||||
private AuthorityService authorityService;
|
||||
private CategoryService categoryService;
|
||||
|
||||
public static final String TEST_TENANT_DOMAIN1 = "yyy.com";
|
||||
public static final String TEST_TENANT_DOMAIN2 = "zzz.com";
|
||||
|
||||
private static List<String> tenants;
|
||||
public static int NUM_TENANTS = 11;
|
||||
|
||||
public static final String TEST_TENANT_DOMAIN = "my.test";
|
||||
public static final String TEST_TENANT_DOMAIN2 = TEST_TENANT_DOMAIN+"2";
|
||||
|
||||
public static List<String> tenants;
|
||||
|
||||
static {
|
||||
tenants = new ArrayList<String>(2);
|
||||
tenants.add(TEST_TENANT_DOMAIN1);
|
||||
tenants.add(TEST_TENANT_DOMAIN2);
|
||||
tenants = new ArrayList<String>(NUM_TENANTS);
|
||||
for (int i = 1; i <= NUM_TENANTS; i++)
|
||||
{
|
||||
tenants.add(TEST_TENANT_DOMAIN+i);
|
||||
}
|
||||
}
|
||||
|
||||
public static final String ROOT_DIR = "./tenantstores";
|
||||
@@ -487,31 +491,33 @@ public class MultiTDemoTest extends TestCase
|
||||
{
|
||||
logger.info("Test get property");
|
||||
|
||||
final String tenantDomain = TEST_TENANT_DOMAIN1;
|
||||
String tenantAdminName = tenantService.getDomainUser(TenantService.ADMIN_BASENAME, tenantDomain);
|
||||
|
||||
AuthenticationUtil.runAs(new RunAsWork<Object>()
|
||||
for (final String tenantDomain : tenants)
|
||||
{
|
||||
public Object doWork() throws Exception
|
||||
String tenantAdminName = tenantService.getDomainUser(TenantService.ADMIN_BASENAME, tenantDomain);
|
||||
|
||||
AuthenticationUtil.runAs(new RunAsWork<Object>()
|
||||
{
|
||||
NodeRef personNodeRef = createUser(TEST_USER4, tenantDomain, "welcome");
|
||||
|
||||
// Test nodeRef property
|
||||
NodeRef homeFolderNodeRef = (NodeRef)nodeService.getProperty(personNodeRef, ContentModel.PROP_HOMEFOLDER);
|
||||
assertFalse(homeFolderNodeRef.toString().contains(tenantDomain));
|
||||
|
||||
Map<QName, Serializable> props = (Map<QName, Serializable>)nodeService.getProperties(personNodeRef);
|
||||
assertFalse(props.get(ContentModel.PROP_HOMEFOLDER).toString().contains(tenantDomain));
|
||||
|
||||
// Test "store-identifier" property
|
||||
String storeId = (String)nodeService.getProperty(personNodeRef, ContentModel.PROP_STORE_IDENTIFIER);
|
||||
assertFalse(storeId.contains(tenantDomain));
|
||||
|
||||
assertFalse(props.get(ContentModel.PROP_STORE_IDENTIFIER).toString().contains(tenantDomain));
|
||||
|
||||
return null;
|
||||
}
|
||||
}, tenantAdminName);
|
||||
public Object doWork() throws Exception
|
||||
{
|
||||
NodeRef personNodeRef = createUser(TEST_USER4, tenantDomain, "welcome");
|
||||
|
||||
// Test nodeRef property
|
||||
NodeRef homeFolderNodeRef = (NodeRef)nodeService.getProperty(personNodeRef, ContentModel.PROP_HOMEFOLDER);
|
||||
assertFalse(homeFolderNodeRef.toString().contains(tenantDomain));
|
||||
|
||||
Map<QName, Serializable> props = (Map<QName, Serializable>)nodeService.getProperties(personNodeRef);
|
||||
assertFalse(props.get(ContentModel.PROP_HOMEFOLDER).toString().contains(tenantDomain));
|
||||
|
||||
// Test "store-identifier" property
|
||||
String storeId = (String)nodeService.getProperty(personNodeRef, ContentModel.PROP_STORE_IDENTIFIER);
|
||||
assertFalse(storeId.contains(tenantDomain));
|
||||
|
||||
assertFalse(props.get(ContentModel.PROP_STORE_IDENTIFIER).toString().contains(tenantDomain));
|
||||
|
||||
return null;
|
||||
}
|
||||
}, tenantAdminName);
|
||||
}
|
||||
}
|
||||
|
||||
private void createGroup(String shortName, String parentShortName)
|
||||
|
Reference in New Issue
Block a user