public class TestGroupResourceCountUsers extends BaseJiraFuncTest
This test compares whether the group counts we calculate (with a direct db query) match the number of users that Crowd considers to be in the group. This ensures our count query matches Crowd's rules around directory shadowing, nested groups, inactive users, etc.
The restored backup file contains multiple user directories with users and groups configured in various ways. Directories are described here, in priority order:
Directory 1 (id = 1002, priority = 0) =========== Group | User ================================ Koalas | Anna | Betty Wombats | Catherine | John (inactive) Wallabies (inactive) | Catherine Sealife | Anna -> Starfish | Betty Lions | Leopold Directory 2 (id = 1001, priority = 1) =========== Group | User ================================ Koalas | Anna | David Wombats | David | John Echidnas | Ernie Sealife | David Starfish | Ernie Directory 3 (INACTIVE) (id = 2001, priority = 2) =========== Group | User ================================ Lions | Leonardo Directory 4 (id = 3001, priority = 3) =========== Group | User ================================ ground | Bill -> hog | Bill -> day | Bill | Andie DiamondTop | White -> DiamondLeft | Pink -> DiamondBottom | Yellow -> DiamondRight | Blue -> (DiamondBottom)| (Yellow) nest1 | Owl -> nest2 | Robin -> nest3 | Frogmouth -> nest4 | Wren -> nest5 | Lorikeet Hall | Louis -> Mirrors | Jules -> (Hall) | (Louis)
Modifier and Type | Field and Description |
---|---|
static String |
GROUP_RESOURCE_COUNT_USERS_XML |
assertions, backdoor, environmentData, initClass, navigation, tester, testRule
Constructor and Description |
---|
TestGroupResourceCountUsers() |
Modifier and Type | Method and Description |
---|---|
void |
countUsersIn2001NestedGroups()
Test a group nesting containing 2001 nested groups can be successfully counted.
|
void |
cycles_cyclicalGroupMembershipsAreCountedCorrectly() |
void |
deeplyNestedGroupsAreCountedCorrectly() |
void |
diamonds_memberOfNestedGroupByTwoRoutesIsCountedOnce() |
void |
getCountOfJiraUsersMembers() |
void |
groupNameIsCaseInsensitive() |
void |
groupsOnlyInLowerPriorityDirectoriesAreFound() |
void |
inactiveDirectoriesAreIgnored() |
void |
inactiveGroupStillHasMembers() |
void |
inactiveShadowedUsersAreIgnored()
A user made inactive by shadowing is not counted.
|
void |
memberOfMultipleNestedGroupsIsCountedOnce() |
void |
membersAreAmalgamatedAcrossDirectories() |
void |
nestedGroupsAreObservedInUsersCanonicalDirectory() |
void |
setup() |
void |
tearDown() |
getAssertions, getBackdoor, getEnvironmentData, getTester
public static final String GROUP_RESOURCE_COUNT_USERS_XML
public void setup()
public void tearDown()
public void membersAreAmalgamatedAcrossDirectories()
public void nestedGroupsAreObservedInUsersCanonicalDirectory()
public void inactiveShadowedUsersAreIgnored()
public void inactiveDirectoriesAreIgnored()
public void inactiveGroupStillHasMembers()
public void groupsOnlyInLowerPriorityDirectoriesAreFound()
public void groupNameIsCaseInsensitive()
public void memberOfMultipleNestedGroupsIsCountedOnce()
public void deeplyNestedGroupsAreCountedCorrectly()
public void diamonds_memberOfNestedGroupByTwoRoutesIsCountedOnce()
public void cycles_cyclicalGroupMembershipsAreCountedCorrectly()
public void countUsersIn2001NestedGroups()
public void getCountOfJiraUsersMembers()
Copyright © 2002-2018 Atlassian. All Rights Reserved.