Do not set KOTLIN_HOME env var for tests

Instead, rework the (already suspicious) KotlinPaths-finding code in
PathUtil to support the new model of running tests (the compiler is
split into several jars according to the project structure) instead of
the old one (where class files were not in the jars, but in the out/
directory).

This fixes Java9ModulesIntegrationTest
This commit is contained in:
Alexander Udalov
2017-09-18 16:36:41 +03:00
committed by Ilya Chernikov
parent 630d090103
commit 8f5dae8f57
2 changed files with 5 additions and 4 deletions
-1
View File
@@ -33,7 +33,6 @@ fun Project.projectTest(taskName: String = "test", body: Test.() -> Unit = {}):
maxHeapSize = "1100m"
systemProperty("idea.is.unit.test", "true")
environment("NO_FS_ROOTS_ACCESS_CHECK", "true")
environment("KOTLIN_HOME", rootProject.extra["distKotlinHomeDir"])
environment("PROJECT_CLASSES_DIRS", the<JavaPluginConvention>().sourceSets.getByName("test").output.classesDirs.asPath)
environment("PROJECT_BUILD_DIR", buildDir)
systemProperty("jps.kotlin.home", rootProject.extra["distKotlinHomeDir"])