protected void testMockClassLoadingMetaData(MockClassLoadingMetaData a, ResourcesAdapter visitor, ResourceFilter filter, ResourceFilter recurseFilter, Set<String> expectedResources) throws Exception
{
KernelControllerContext contextA = install(a);
try
{
MockClassLoaderPolicyModule module = assertModule(contextA);
module.registerClassLoaderPolicy(system);
if (recurseFilter != null)
{
if (filter != null)
module.visit(visitor, filter, recurseFilter);
else
module.visit(visitor, visitor.getFilter(), recurseFilter);
}
else if (filter != null)
{
module.visit(visitor, filter);
}
else
{
module.visit(visitor);
}
assertEquals(expectedResources, visitor.getResources());
}
finally