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

Build into test-classes dir.

This commit is contained in:
Cedric Beust 2015-12-09 09:52:05 -08:00
parent d8e893be9e
commit c8d6ab9af0

View file

@ -179,7 +179,8 @@ abstract class JvmCompilerPlugin @Inject constructor(
dependencyManager.dependencies(project, context, projects)
val projectDirectory = File(project.directory)
val buildDirectory = File(project.classesDir(context))
val buildDirectory = if (isTest) KFiles.makeOutputTestDir(project)
else File(project.classesDir(context))
buildDirectory.mkdirs()
val initialSourceDirectories = arrayListOf<File>()
@ -199,7 +200,7 @@ abstract class JvmCompilerPlugin @Inject constructor(
context.pluginInfo.sourceDirectoriesInterceptors.fold(initialSourceDirectories.toList(),
{ sd, interceptor -> interceptor.intercept(project, context, sd) })
}.filter {
it.exists()
File(project.directory, it.path).exists()
}
// Now that we have the final list of source dirs, find source files in them