1
0
Fork 0
mirror of https://github.com/ethauvin/kobalt.git synced 2025-04-26 08:27:12 -07:00

Fix classpath.

This commit is contained in:
Cedric Beust 2016-05-31 20:35:45 -07:00
parent 276f9e9602
commit af846f2e20

View file

@ -205,12 +205,13 @@ class DependencyManager @Inject constructor(val executors: KobaltExecutors, val
// Make sure that classes/ and test-classes/ are always at the top of this classpath,
// so that older versions of that project on the classpath don't shadow them
val result : ArrayList<IClasspathDependency> =
arrayListOf(FileDependency(KFiles.makeOutputDir(project).absolutePath))
if (isTest) {
result.add(FileDependency(KFiles.makeOutputTestDir(project).absolutePath))
val result = arrayListOf<IClasspathDependency>().apply {
if (isTest) {
add(FileDependency(KFiles.makeOutputDir(project).absolutePath))
add(FileDependency(KFiles.makeOutputTestDir(project).absolutePath))
}
addAll(reorderDependencies(transitive))
}
result.addAll(reorderDependencies(transitive))
return result
}