use of org.jetbrains.plugins.gradle.model.ClasspathEntryModel in project intellij-community by JetBrains.
the class AbstractModelBuilderTest method assertBuildClasspath.
protected void assertBuildClasspath(String projectPath, String... classpath) {
final Map<String, BuildScriptClasspathModel> classpathModelMap = getModulesMap(BuildScriptClasspathModel.class);
final BuildScriptClasspathModel classpathModel = classpathModelMap.get(projectPath);
assertNotNull(classpathModel);
final List<? extends ClasspathEntryModel> classpathEntryModels = classpathModel.getClasspath().getAll();
assertEquals(classpath.length, classpathEntryModels.size());
for (int i = 0, length = classpath.length; i < length; i++) {
String classpathEntry = classpath[i];
final ClasspathEntryModel classpathEntryModel = classpathEntryModels.get(i);
assertNotNull(classpathEntryModel);
assertEquals(1, classpathEntryModel.getClasses().size());
final String path = classpathEntryModel.getClasses().iterator().next();
assertEquals(classpathEntry, new File(path).getName());
}
}
Aggregations