From 0f4684da67786d9dca076804fb712b5a842a33b1 Mon Sep 17 00:00:00 2001 From: Alexander Udalov Date: Wed, 28 Jun 2017 20:22:30 +0300 Subject: [PATCH] Fix codegen tests on JDK 9 with jdkKind = FULL_JDK --- .../org/jetbrains/kotlin/test/KotlinTestUtils.java | 3 +++ 1 file changed, 3 insertions(+) diff --git a/compiler/tests-common/org/jetbrains/kotlin/test/KotlinTestUtils.java b/compiler/tests-common/org/jetbrains/kotlin/test/KotlinTestUtils.java index 0908e531e92..922f2ce621a 100644 --- a/compiler/tests-common/org/jetbrains/kotlin/test/KotlinTestUtils.java +++ b/compiler/tests-common/org/jetbrains/kotlin/test/KotlinTestUtils.java @@ -506,6 +506,9 @@ public class KotlinTestUtils { configuration.put(JVMConfigurationKeys.JDK_HOME, home); } } + else if (SystemInfo.IS_AT_LEAST_JAVA9) { + configuration.put(JVMConfigurationKeys.JDK_HOME, new File(System.getProperty("java.home"))); + } else { JvmContentRootsKt.addJvmClasspathRoots(configuration, PathUtil.getJdkClassesRootsFromCurrentJre()); }