}
public void testGetResourceFromParentAfter() throws Exception
{
ClassLoaderSystem system = createClassLoaderSystem();
ClassLoaderDomain parent = system.createAndRegisterDomain("parent");
MockClassLoaderPolicy policy = createMockClassLoaderPolicy();
policy.setPrefix("a/");
policy.setPath("com/acme/p1");
policy.setPackageNames(new String[] { "com.acme.p1" } );
system.registerClassLoaderPolicy(parent, policy);
ClassLoaderDomain child = system.createAndRegisterDomain("child", ParentPolicy.AFTER, parent);
MockClassLoaderPolicy policy2 = createMockClassLoaderPolicy();
ClassLoader classLoader = system.registerClassLoaderPolicy(child, policy2);
assertGetResource("a/", "com/acme/p1/testResource", classLoader);
}