Add implements common dependency for regular multiplatform tests
This commit is contained in:
+3
-2
@@ -40,7 +40,8 @@ abstract class AbstractMultiModuleHighlightingTest : AbstractMultiHighlightingTe
|
|||||||
configureModule: (Module, TargetPlatformKind<*>) -> Unit = { _, _ -> },
|
configureModule: (Module, TargetPlatformKind<*>) -> Unit = { _, _ -> },
|
||||||
jdk: TestJdkKind = TestJdkKind.MOCK_JDK
|
jdk: TestJdkKind = TestJdkKind.MOCK_JDK
|
||||||
) {
|
) {
|
||||||
val commonModule = module("common", jdk)
|
val commonModuleName = "common"
|
||||||
|
val commonModule = module(commonModuleName, jdk)
|
||||||
commonModule.createFacet(TargetPlatformKind.Common, false)
|
commonModule.createFacet(TargetPlatformKind.Common, false)
|
||||||
if (withStdlibCommon) {
|
if (withStdlibCommon) {
|
||||||
commonModule.addLibrary(ForTestCompileRuntime.stdlibCommonForTests(), kind = CommonLibraryKind)
|
commonModule.addLibrary(ForTestCompileRuntime.stdlibCommonForTests(), kind = CommonLibraryKind)
|
||||||
@@ -53,7 +54,7 @@ abstract class AbstractMultiModuleHighlightingTest : AbstractMultiHighlightingTe
|
|||||||
else -> error("Unsupported platform: $platform")
|
else -> error("Unsupported platform: $platform")
|
||||||
}
|
}
|
||||||
val platformModule = module(path, jdk)
|
val platformModule = module(path, jdk)
|
||||||
platformModule.createFacet(platform)
|
platformModule.createFacet(platform, implementedModuleName = commonModuleName)
|
||||||
platformModule.enableMultiPlatform()
|
platformModule.enableMultiPlatform()
|
||||||
platformModule.addDependency(commonModule)
|
platformModule.addDependency(commonModule)
|
||||||
configureModule(platformModule, platform)
|
configureModule(platformModule, platform)
|
||||||
|
|||||||
Reference in New Issue
Block a user