*
* @throws Exception if an error occurs while running the test.
*/
public void testGetEntitlements() throws Exception
{
Resource resource1 = new ACLTestResource(10);
Resource resource2 = new ACLTestResource(20);
// for testing purposes, lets say resource2 is a child of resource1.
Collection<Resource> childResources = new ArrayList<Resource>();
// resource 1 has resource 2 as child.
childResources.add(resource2);
resource1.getMap().put(ResourceKeys.CHILD_RESOURCES, childResources);
resource2.getMap().put(ResourceKeys.PARENT_RESOURCE, resource1);
// using the authorization manager, check the entitlements assigned to some of the identities.
JBossAuthorizationManager jam = new JBossAuthorizationManager("test-acl");
// start with the Administrator identity.