mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-08-07 17:49:17 +00:00
ETHREEOH-2133 Creating a duplicate 'private' site returns permission denied instead of meaningful error
- The pre-existing test is now run as root. git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@14794 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
@@ -177,8 +177,37 @@ public class SiteServiceImplTest extends BaseAlfrescoSpringTest
|
||||
{
|
||||
// Expected
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* Test for duplicate site exception where the duplicate is a private site.
|
||||
*
|
||||
* @throws Exception
|
||||
*/
|
||||
public void testETHREEOH_2133() throws Exception
|
||||
{
|
||||
|
||||
// Test for duplicate site error with a private site
|
||||
|
||||
this.siteService.createSite(TEST_SITE_PRESET, "wibble", TEST_TITLE, TEST_DESCRIPTION, SiteVisibility.PRIVATE);
|
||||
|
||||
authenticationComponent.setCurrentUser(USER_THREE);
|
||||
|
||||
try
|
||||
{
|
||||
this.siteService.createSite(TEST_SITE_PRESET, "wibble", TEST_TITLE, TEST_DESCRIPTION, SiteVisibility.PRIVATE);
|
||||
fail("Shouldn't allow duplicate site short names.");
|
||||
}
|
||||
catch (AlfrescoRuntimeException exception)
|
||||
{
|
||||
// Expected
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
public void testETHREEOH_15() throws Exception
|
||||
{
|
||||
SiteInfo siteInfo = this.siteService.createSite(TEST_SITE_PRESET, "mySiteTest", TEST_TITLE, TEST_DESCRIPTION, SiteVisibility.PUBLIC);
|
||||
|
Reference in New Issue
Block a user