01fc708a0f
^KT-61573 Fixed Review: https://jetbrains.team/p/kt/reviews/11969/timeline Tests: - MultiPlatformIntegrationTestGenerated - CliTestGenerated - MultiPlatformIntegrationTestGenerated - DiagnosticTestGenerated.Multiplatform - FirLightTreeOldFrontendDiagnosticsTestGenerated Also add -Xexpect-actual-classes flag to all necessary ./libraries/* modules Otherwise compilation of those modules failes because of `-Werror`
51 lines
1.1 KiB
Groovy
51 lines
1.1 KiB
Groovy
description = 'Kotlin Test JUnit'
|
|
|
|
apply plugin: 'kotlin-platform-jvm'
|
|
|
|
JvmToolchain.configureJvmToolchain(project, JdkMajorVersion.JDK_1_8)
|
|
|
|
def includeJava9 = BuildPropertiesExtKt.getIncludeJava9(project.kotlinBuildProperties)
|
|
|
|
sourceSets {
|
|
if (includeJava9) {
|
|
java9
|
|
}
|
|
}
|
|
|
|
dependencies {
|
|
expectedBy project(':kotlin-test:kotlin-test-annotations-common')
|
|
api project(':kotlin-test:kotlin-test-jvm')
|
|
api('junit:junit:4.13.2')
|
|
}
|
|
|
|
|
|
jar {
|
|
LibrariesCommon.manifestAttributes(project, manifest, 'Test', true)
|
|
if (includeJava9) {
|
|
from sourceSets.java9.output
|
|
}
|
|
}
|
|
|
|
RepoArtifacts.sourcesJar(project)
|
|
RepoArtifacts.javadocJar(project)
|
|
|
|
compileKotlin {
|
|
kotlinOptions.freeCompilerArgs = [
|
|
"-Xallow-kotlin-package",
|
|
"-Xexpect-actual-classes",
|
|
]
|
|
kotlinOptions.moduleName = project.name
|
|
}
|
|
|
|
compileTestKotlin {
|
|
kotlinOptions.freeCompilerArgs = [
|
|
"-Xallow-kotlin-package",
|
|
]
|
|
}
|
|
|
|
LibrariesCommon.configureFrontendIr(project)
|
|
|
|
if (includeJava9) {
|
|
LibrariesCommon.configureJava9Compilation(project, 'kotlin.test.junit')
|
|
}
|