From 5e108d8efd1df4c7db1e7fc0412faec44c8e5c1b Mon Sep 17 00:00:00 2001 From: Ilya Chernikov Date: Fri, 15 Sep 2017 17:24:30 +0200 Subject: [PATCH] Fix stdlib test in compiler in the gradle environment --- compiler/tests/org/jetbrains/kotlin/codegen/StdlibTest.java | 2 +- .../jetbrains/kotlin/idea/highlighter/NoErrorsInStdlibTest.kt | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/compiler/tests/org/jetbrains/kotlin/codegen/StdlibTest.java b/compiler/tests/org/jetbrains/kotlin/codegen/StdlibTest.java index cd53406ccdd..55f2063d5f6 100644 --- a/compiler/tests/org/jetbrains/kotlin/codegen/StdlibTest.java +++ b/compiler/tests/org/jetbrains/kotlin/codegen/StdlibTest.java @@ -53,7 +53,7 @@ public class StdlibTest extends KotlinTestWithEnvironment { @Override protected KotlinCoreEnvironment createEnvironment() { @SuppressWarnings("deprecation") - File[] runtimeClasspath = ForTestCompileRuntime.runtimeClassesForTests(); + File[] runtimeClasspath = new File[] { ForTestCompileRuntime.runtimeJarForTests() }; CompilerConfiguration configuration = KotlinTestUtils.newConfiguration(ConfigurationKind.JDK_NO_RUNTIME, TestJdkKind.FULL_JDK, runtimeClasspath); JvmContentRootsKt.addJvmClasspathRoot(configuration, ForTestCompileRuntime.kotlinTestJarForTests()); diff --git a/idea/tests/org/jetbrains/kotlin/idea/highlighter/NoErrorsInStdlibTest.kt b/idea/tests/org/jetbrains/kotlin/idea/highlighter/NoErrorsInStdlibTest.kt index f7f5fc50b1a..12f654d04bb 100644 --- a/idea/tests/org/jetbrains/kotlin/idea/highlighter/NoErrorsInStdlibTest.kt +++ b/idea/tests/org/jetbrains/kotlin/idea/highlighter/NoErrorsInStdlibTest.kt @@ -67,7 +67,7 @@ class NoErrorsInStdlibTest : KotlinLightCodeInsightFixtureTestCase() { override fun getProjectDescriptor(): LightProjectDescriptor { // TODO: replace hardcoded path with something flexible - return object : KotlinJdkAndLibraryProjectDescriptor(File("build/kotlin-stdlib/classes/java/builtins")) { + return object : KotlinJdkAndLibraryProjectDescriptor(File("dist/kotlinc/lib/kotlin-stdlib.jar")) { override fun getSdk(): Sdk? = PluginTestCaseBase.fullJdk() } }