{
SecurityEntry securityEntry = (SecurityEntry) securityIterator.next();
if (securityEntry.getName().equals("wide_open") == true)
{
entryFound = true;
SecurityReference securityReference = securityEntry.getSecurityRef();
assertNotNull("Security entry 'wide_open' has a SecurityReference", securityReference);
assertEquals("Got parent", "admin_only", securityReference.getParent());
}
}
assertTrue("Found wide_open security entry", entryFound);
// Test the use_only entry
entryFound = false;
for (securityIterator = securityEntries.iterator(); securityIterator.hasNext();)
{
SecurityEntry securityEntry = (SecurityEntry) securityIterator.next();
if (securityEntry.getName().equals("user_only") == true)
{
entryFound = true;
SecurityReference securityReference = securityEntry.getSecurityRef();
assertNull("Security entry 'user_open' has no SecurityReference", securityReference);
}
}
assertEquals("Found user_only security entry", true, entryFound);
}