From 33de7bdf25bad30ee86290e1c079b004df44da4d Mon Sep 17 00:00:00 2001 From: "Vadim.Mishenev" Date: Thu, 26 Oct 2023 00:38:21 +0300 Subject: [PATCH] Replace common stdlib in unit tests --- .../src/main/kotlin/testApi/testRunner/TestRunner.kt | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/core/test-api/src/main/kotlin/testApi/testRunner/TestRunner.kt b/core/test-api/src/main/kotlin/testApi/testRunner/TestRunner.kt index 23300190aa..0ae1af7fb3 100644 --- a/core/test-api/src/main/kotlin/testApi/testRunner/TestRunner.kt +++ b/core/test-api/src/main/kotlin/testApi/testRunner/TestRunner.kt @@ -191,12 +191,11 @@ public abstract class AbstractTest, D : Dokk ?.replaceAfter(".jar", "") } - protected val commonStdlibPath: String? by lazy { - // TODO: feels hacky, find a better way to do it - ClassLoader.getSystemResource("kotlin/UInt.kotlin_metadata") - ?.file - ?.replace("file:", "") - ?.replaceAfter(".jar", "") + protected val commonStdlibPath: String? by lazy { + // `kotlin-stdlib-common` is legacy + // we can use any platform dependency + // since common code should be resolved with all platform + jvmStdlibPath } protected val stdlibExternalDocumentationLink: ExternalDocumentationLinkImpl = ExternalDocumentationLinkImpl(