eaReport.setModuleDescriptor(md.getIvyModuleDescriptor());
Project p = buildProject(null);
Target implicitTarget = ProjectUtils.createTopLevelTarget();
p.addTarget("", implicitTarget);
LoadModule loadModule = new LoadModule();
loadModule.setBuildModule(moduleDescriptor);
loadModule.setBuildFile(optionalAntModule);
loadModule.setOwningTarget(implicitTarget);
loadModule.setLocation(new Location(ProjectUtils.emulateMainScript(p).getAbsolutePath()));
loadModule.setProject(p);
loadModule.execute();
ProjectUtils.injectTargetIntoExtensionPoint(p, ProjectUtils.getConfiguredProjectHelper(p));
analyseProject(p, eaReport, "default");
return eaReport;
}