Remove separate test configurations for JDK 21

^KT-58765

Now that JDK 21 was released as stable, we can remove separate test
configurations for testing the compiler with JDK 21 and reintegrate
the corresponding test data into standard test configurations.
This commit is contained in:
Stanislav Ruban
2024-01-08 18:24:25 +02:00
committed by Space Team
parent 13b3987aab
commit a5bae12915
7 changed files with 26 additions and 120 deletions
+7 -25
View File
@@ -62,37 +62,19 @@ if (kotlinBuildProperties.isInJpsBuildIdeaSync) {
}
}
fun Test.configureTest(configureJUnit: JUnitPlatformOptions.() -> Unit = {}) {
dependsOn(":dist")
workingDir = rootDir
useJUnitPlatform {
configureJUnit()
}
useJsIrBoxTests(version = version, buildDir = layout.buildDirectory)
}
projectTest(
jUnitMode = JUnitMode.JUnit5,
defineJDKEnvVariables = listOf(JdkMajorVersion.JDK_1_8, JdkMajorVersion.JDK_11_0, JdkMajorVersion.JDK_17_0)
) {
configureTest {
excludeTags("Jdk21Test")
}
}
// Separate configuration is only necessary while JDK 21 is not released, so cannot be obtained via toolchain.
// See KT-58765 for tracking
projectTest(
"jdk21Tests",
jUnitMode = JUnitMode.JUnit5,
defineJDKEnvVariables = listOf(
JdkMajorVersion.JDK_1_8,
JdkMajorVersion.JDK_11_0,
JdkMajorVersion.JDK_17_0,
JdkMajorVersion.JDK_21_0
)
) {
configureTest {
includeTags("Jdk21Test")
}
dependsOn(":dist")
workingDir = rootDir
useJUnitPlatform()
useJsIrBoxTests(version = version, buildDir = layout.buildDirectory)
}
testsJar()