diff --git a/js/js.tests/build.gradle.kts b/js/js.tests/build.gradle.kts index 967bf1040c8..0e7e0de16f4 100644 --- a/js/js.tests/build.gradle.kts +++ b/js/js.tests/build.gradle.kts @@ -16,7 +16,11 @@ node { } val antLauncherJar by configurations.creating -val testJsRuntime by configurations.creating +val testJsRuntime by configurations.creating { + attributes { + attribute(LibraryElements.LIBRARY_ELEMENTS_ATTRIBUTE, objects.named(LibraryElements.JAR)) + } +} dependencies { testRuntime(intellijDep()) diff --git a/libraries/kotlin.test/js/it/build.gradle b/libraries/kotlin.test/js/it/build.gradle index 1cba035eef7..e76b7d8015f 100644 --- a/libraries/kotlin.test/js/it/build.gradle +++ b/libraries/kotlin.test/js/it/build.gradle @@ -6,6 +6,15 @@ description = 'Kotlin-test integration tests for JS' apply plugin: 'kotlin-platform-js' +configurations { + nodeModules { + extendsFrom testCompile + attributes { + attribute(LibraryElements.LIBRARY_ELEMENTS_ATTRIBUTE, objects.named(LibraryElements, LibraryElements.JAR)) + } + } +} + dependencies { compile project(':kotlin-test:kotlin-test-js') } @@ -19,9 +28,10 @@ buildDir = "$projectDir/build" task populateNodeModules(type: Copy, dependsOn: compileKotlin2Js) { from compileKotlin2Js.destinationDir + dependsOn(configurations.nodeModules) from { - configurations.testCompile.collect { + configurations.nodeModules.collect { zipTree(it.absolutePath).matching { include '*.js' } } } diff --git a/prepare/compiler/build.gradle.kts b/prepare/compiler/build.gradle.kts index 17df0c969a1..ad5286e95e0 100644 --- a/prepare/compiler/build.gradle.kts +++ b/prepare/compiler/build.gradle.kts @@ -35,6 +35,9 @@ val proguardLibraries by configurations.creating { // Libraries to copy to the lib directory val libraries by configurations.creating { exclude("org.jetbrains.kotlin", "kotlin-stdlib-common") + attributes { + attribute(LibraryElements.LIBRARY_ELEMENTS_ATTRIBUTE, objects.named(LibraryElements.JAR)) + } } // Compiler plugins should be copied without `kotlin-` prefix