assertFalse(getArchiveFileInCache("org11", "mod11.1", "1.0", "mod11.1", "jar", "jar")
.exists());
}
public void testResolveDualChain() throws Exception {
Ivy ivy = new Ivy();
ivy.configure(ResolveTest.class.getResource("dualchainresolverconf.xml"));
DependencyResolver resolver = ivy.getSettings().getResolver("default");
assertNotNull(resolver);
assertTrue(resolver instanceof DualResolver);
// first without cache
ivy.resolve(ResolveTest.class.getResource("ivy-dualchainresolver.xml"),
getResolveOptions(new String[] {"default"}));
assertTrue(new File("build/cache/xerces/xerces/ivy-2.6.2.xml").exists());
assertTrue(new File("build/cache/xerces/xerces/jars/xmlParserAPIs-2.6.2.jar").exists());
assertTrue(new File("build/cache/xerces/xerces/jars/xercesImpl-2.6.2.jar").exists());
// second with cache for ivy file only
new File("build/cache/xerces/xerces/jars/xmlParserAPIs-2.6.2.jar").delete();
new File("build/cache/xerces/xerces/jars/xercesImpl-2.6.2.jar").delete();
assertFalse(new File("build/cache/xerces/xerces/jars/xmlParserAPIs-2.6.2.jar").exists());
assertFalse(new File("build/cache/xerces/xerces/jars/xercesImpl-2.6.2.jar").exists());
ivy.resolve(ResolveTest.class.getResource("ivy-dualchainresolver.xml"),
getResolveOptions(new String[] {"default"}));
assertTrue(new File("build/cache/xerces/xerces/ivy-2.6.2.xml").exists());
assertTrue(new File("build/cache/xerces/xerces/jars/xmlParserAPIs-2.6.2.jar").exists());
assertTrue(new File("build/cache/xerces/xerces/jars/xercesImpl-2.6.2.jar").exists());