com.atlassian.confluence
Class EditGlobalPermissionsAcceptanceTest

java.lang.Object
  extended by junit.framework.Assert
      extended by junit.framework.TestCase
          extended by com.atlassian.confluence.junit3.JUnit3TimingTestCase
              extended by com.atlassian.confluence.AbstractConfluenceAcceptanceTest
                  extended by com.atlassian.confluence.AbstractPermissionsAcceptanceTest
                      extended by com.atlassian.confluence.EditGlobalPermissionsAcceptanceTest
All Implemented Interfaces:
junit.framework.Test

public class EditGlobalPermissionsAcceptanceTest
extends AbstractPermissionsAcceptanceTest

Tests adding and removing various permissions in the Edit Global Permissions screen. May have a bit of overlap with the classes that Test the effectiveness of the permissions.

todo: Make this class work with LDAP. It's pretty broken at the moment.

See Also:
GlobalAdminAcceptanceTest

Field Summary
static java.util.List<GlobalPermission> GLOBAL_PERMISSIONS
          The set of permissions available on the "Edit Global Permissions" screen, minus system-administrator.
 
Fields inherited from class com.atlassian.confluence.AbstractPermissionsAcceptanceTest
ADMIN_GROUP_PERMISSION
 
Fields inherited from class com.atlassian.confluence.AbstractConfluenceAcceptanceTest
DASHBOARD_RECENT_UPDATES_URL, log, logAdjuster, RANDOM, rpc, TEST_ADMIN, TEST_BLOG, TEST_COMMENT, TEST_GROUP1, TEST_GROUP2, TEST_PAGE, TEST_SPACE, TEST_SPACE2, TEST_USER1, TEST_USER2, TESTBLOG_CONTENT, TESTBLOG_TITLE, testData, TESTPAGE_COMMENT, TESTPAGE_CONTENT, TESTPAGE_TITLE, TESTSPACE_KEY, TESTSPACE_TITLE, TESTSPACE2_KEY, TESTSPACE2_TITLE, webTester, wikiMarkupRpc
 
Constructor Summary
EditGlobalPermissionsAcceptanceTest()
           
 
Method Summary
 void setUp()
          Default setUp method.
 void testCanGiveGroupConfluenceAdministratorPermission()
           
 void testCanGiveUserConfluenceAdministratorPermission()
           
 void testCanGrantGroupSystemAdministratorPermissionAsSystemAdministrator()
           
 void testCanGrantUserSystemAdministratorPermissionAsSystemAdministrator()
           
 void testCannotGrantGroupSystemAdministratorPermissionAsConfluenceAdministrator()
           
 void testCannotGrantUserSystemAdministratorPermissionAsConfluenceAdministrator()
           
 void testCannotRemoveGroupSystemAdministratorPermissionAsConfluenceAdministrator()
           
 void testCannotRemoveLastSystemAdministratorPermission()
           
 void testCannotRemoveUserSystemAdministratorPermissionAsConfluenceAdministrator()
           
 void testCannotRevokeConfluenceUsePermissionFromSystemAdminAsConfAdmin()
           
 void testCannotSetPermissionsOnSysAdminAsConfAdmin()
           
 void testCannotSetPermissionsOnSysAdminGroupAsConfAdmin()
           
 void testCanRemoveConfluenceAdministratorPermissionFromGroup()
           
 void testCanRemoveConfluenceAdministratorPermissionFromUser()
           
 void testCanRemoveGroupSystemAdministratorPermissionAsSystemAdministrator()
           
 void testCanRemoveUserSystemAdministratorPermissionAsSystemAdministrator()
           
 void testCanRevokeConfluenceUsePermissionFromSysAdminAsAnotherSysAdmin()
           
 void testCanSetAnonymousUsePermission()
           
 void testCanSetPermissionsOnNormalGroupsAsConfAdmin()
           
 void testCanSetPermissionsOnNormalUsersAsConfAdmin()
           
 void testCanUseRequiredForAnonymousPermissions()
          Test that more specific anonymous permissions cannot be set unless the anonymous can use permission is also set.
 void testPermissionTabs()
           
 
Methods inherited from class com.atlassian.confluence.AbstractPermissionsAcceptanceTest
assertUserHasNoPermissionsInViewPermissionsTable, removeViewPermissions
 
Methods inherited from class com.atlassian.confluence.AbstractConfluenceAcceptanceTest
adminConsole, attachments, createSpaceViaWebUI, createTestSpaceViaWebUI, directoryConfig, generateBaseUrl, generateFile, getAppContext, getBaseUrl, getConfiguredBaseUrl, getPluginHelper, getServerStateManager, goToBlogCollector, logInAsAdminAtHomepage, loginAsTestUser, loginAsTestUser2, loginAsTestUserAtHomepage, logins, logout, pages, rebuildIndex, setUpTestNG, tearDown, tearDownTestNG, users, viewHomepage, viewSpaceAdmin, viewSpacePermissions, viewSpaceSummary, viewSpaceTools, viewTrash, watchSpace, webAppContextPath
 
Methods inherited from class com.atlassian.confluence.junit3.JUnit3TimingTestCase
runBare, setExceptionTransformer
 
Methods inherited from class junit.framework.TestCase
countTestCases, createResult, getName, run, run, runTest, setName, toString
 
Methods inherited from class junit.framework.Assert
assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertFalse, assertFalse, assertNotNull, assertNotNull, assertNotSame, assertNotSame, assertNull, assertNull, assertSame, assertSame, assertTrue, assertTrue, fail, fail
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

GLOBAL_PERMISSIONS

public static final java.util.List<GlobalPermission> GLOBAL_PERMISSIONS
The set of permissions available on the "Edit Global Permissions" screen, minus system-administrator. Note that CAN_USE is last, in case we're revoking permissions.

Constructor Detail

EditGlobalPermissionsAcceptanceTest

public EditGlobalPermissionsAcceptanceTest()
Method Detail

setUp

public void setUp()
           throws java.lang.Exception
Description copied from class: AbstractConfluenceAcceptanceTest
Default setUp method. Establishes XML-RPC connection and sets the base URL. Also configures LDAP repository.

Overrides:
setUp in class AbstractConfluenceAcceptanceTest
Throws:
java.lang.Exception - from super

testCanGiveUserConfluenceAdministratorPermission

public void testCanGiveUserConfluenceAdministratorPermission()
                                                      throws java.lang.Exception
Throws:
java.lang.Exception

testCanGrantUserSystemAdministratorPermissionAsSystemAdministrator

public void testCanGrantUserSystemAdministratorPermissionAsSystemAdministrator()
                                                                        throws java.lang.Exception
Throws:
java.lang.Exception

testCannotGrantUserSystemAdministratorPermissionAsConfluenceAdministrator

public void testCannotGrantUserSystemAdministratorPermissionAsConfluenceAdministrator()
                                                                               throws java.lang.Exception
Throws:
java.lang.Exception

testCanRemoveUserSystemAdministratorPermissionAsSystemAdministrator

public void testCanRemoveUserSystemAdministratorPermissionAsSystemAdministrator()
                                                                         throws java.lang.Exception
Throws:
java.lang.Exception

testCannotRemoveUserSystemAdministratorPermissionAsConfluenceAdministrator

public void testCannotRemoveUserSystemAdministratorPermissionAsConfluenceAdministrator()
                                                                                throws java.lang.Exception
Throws:
java.lang.Exception

testCanGrantGroupSystemAdministratorPermissionAsSystemAdministrator

public void testCanGrantGroupSystemAdministratorPermissionAsSystemAdministrator()
                                                                         throws java.lang.Exception
Throws:
java.lang.Exception

testCannotGrantGroupSystemAdministratorPermissionAsConfluenceAdministrator

public void testCannotGrantGroupSystemAdministratorPermissionAsConfluenceAdministrator()
                                                                                throws java.lang.Exception
Throws:
java.lang.Exception

testCanRemoveGroupSystemAdministratorPermissionAsSystemAdministrator

public void testCanRemoveGroupSystemAdministratorPermissionAsSystemAdministrator()
                                                                          throws java.lang.Exception
Throws:
java.lang.Exception

testCannotRemoveGroupSystemAdministratorPermissionAsConfluenceAdministrator

public void testCannotRemoveGroupSystemAdministratorPermissionAsConfluenceAdministrator()
                                                                                 throws java.lang.Exception
Throws:
java.lang.Exception

testCanGiveGroupConfluenceAdministratorPermission

public void testCanGiveGroupConfluenceAdministratorPermission()
                                                       throws java.lang.Exception
Throws:
java.lang.Exception

testCanRemoveConfluenceAdministratorPermissionFromUser

public void testCanRemoveConfluenceAdministratorPermissionFromUser()
                                                            throws java.lang.Exception
Throws:
java.lang.Exception

testCanRemoveConfluenceAdministratorPermissionFromGroup

public void testCanRemoveConfluenceAdministratorPermissionFromGroup()
                                                             throws java.lang.Exception
Throws:
java.lang.Exception

testCannotRemoveLastSystemAdministratorPermission

public void testCannotRemoveLastSystemAdministratorPermission()

testCannotRevokeConfluenceUsePermissionFromSystemAdminAsConfAdmin

public void testCannotRevokeConfluenceUsePermissionFromSystemAdminAsConfAdmin()

testCanRevokeConfluenceUsePermissionFromSysAdminAsAnotherSysAdmin

public void testCanRevokeConfluenceUsePermissionFromSysAdminAsAnotherSysAdmin()

testCannotSetPermissionsOnSysAdminAsConfAdmin

public void testCannotSetPermissionsOnSysAdminAsConfAdmin()

testCannotSetPermissionsOnSysAdminGroupAsConfAdmin

public void testCannotSetPermissionsOnSysAdminGroupAsConfAdmin()

testPermissionTabs

public void testPermissionTabs()

testCanSetPermissionsOnNormalUsersAsConfAdmin

public void testCanSetPermissionsOnNormalUsersAsConfAdmin()

testCanSetPermissionsOnNormalGroupsAsConfAdmin

public void testCanSetPermissionsOnNormalGroupsAsConfAdmin()

testCanUseRequiredForAnonymousPermissions

public void testCanUseRequiredForAnonymousPermissions()
Test that more specific anonymous permissions cannot be set unless the anonymous can use permission is also set.


testCanSetAnonymousUsePermission

public void testCanSetAnonymousUsePermission()


Copyright © 2003-2014 Atlassian. All Rights Reserved.