Skip to content

Commit 1e1810c

Browse files
authored
Update the gradle plugin tests after kotlin 2.1.0 (#5210)
1 parent f9c8448 commit 1e1810c

File tree

12 files changed

+8
-178
lines changed

12 files changed

+8
-178
lines changed

gradle-plugins/compose/src/test/kotlin/org/jetbrains/compose/test/tests/integration/KotlinCompatibilityTest.kt

Lines changed: 5 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -12,21 +12,17 @@ import org.jetbrains.compose.test.utils.checks
1212
import org.junit.jupiter.api.Test
1313

1414
class KotlinCompatibilityTest : GradlePluginTestBase() {
15-
@Test
16-
fun testKotlinMpp_1_9_10() = testMpp("1.9.10")
17-
18-
@Test
19-
fun testKotlinJsMpp_1_9_24() = testJsMpp("1.9.24")
2015

16+
// Note: we can't test non-jvm targets with Kotlin older than 2.1.0, because of klib abi version bump in 2.1.0
2117
@Test
22-
fun testKotlinMpp_1_9_20() = testMpp("1.9.20")
18+
fun testKotlinMpp_2_1_0() = testMpp("2.1.0")
2319

2420
@Test
25-
fun testKotlinJsMpp_1_9_20() = testJsMpp("1.9.20")
21+
fun testKotlinJsMpp_2_1_0() = testJsMpp("2.1.0")
2622

2723
private fun testMpp(kotlinVersion: String) = with(
2824
testProject(
29-
"beforeKotlin2/mpp",
25+
"application/mpp",
3026
testEnvironment = defaultTestEnvironment.copy(kotlinVersion = kotlinVersion)
3127
)
3228
) {
@@ -39,7 +35,7 @@ class KotlinCompatibilityTest : GradlePluginTestBase() {
3935

4036
private fun testJsMpp(kotlinVersion: String) = with(
4137
testProject(
42-
"beforeKotlin2/jsMpp",
38+
"application/jsMpp",
4339
testEnvironment = defaultTestEnvironment.copy(kotlinVersion = kotlinVersion)
4440
)
4541
) {
@@ -87,15 +83,6 @@ class KotlinCompatibilityTest : GradlePluginTestBase() {
8783
)
8884
).checkCustomComposeCompiler()
8985

90-
@Test
91-
fun testKotlinCheckDisabled() = testProject(
92-
"beforeKotlin2/custom-compiler-args", defaultTestEnvironment.copy(
93-
kotlinVersion = "1.9.21",
94-
composeCompilerPlugin = "dependencies.compiler.forKotlin(\"1.9.20\")",
95-
composeCompilerArgs = "\"suppressKotlinVersionCompatibilityCheck=1.9.21\""
96-
)
97-
).checkCustomComposeCompiler(checkKJS = true)
98-
9986
private fun TestProject.checkCustomComposeCompiler(checkKJS: Boolean = false) {
10087
gradle(":runDistributable").checks {
10188
val actualMainImage = file("main-image.actual.png")

gradle-plugins/compose/src/test/kotlin/org/jetbrains/compose/test/tests/integration/ResourcesTest.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -243,7 +243,7 @@ class ResourcesTest : GradlePluginTestBase() {
243243

244244
@Test
245245
fun testMultiModuleResources() {
246-
val environment = defaultTestEnvironment.copy(kotlinVersion = "2.0.0")
246+
val environment = defaultTestEnvironment
247247
with(
248248
testProject("misc/kmpResourcePublication", environment)
249249
) {

gradle-plugins/compose/src/test/test-projects/beforeKotlin2/jsMpp/build.gradle renamed to gradle-plugins/compose/src/test/test-projects/application/jsMpp/build.gradle

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
plugins {
22
id "org.jetbrains.kotlin.multiplatform"
33
id "org.jetbrains.compose"
4+
id "org.jetbrains.kotlin.plugin.compose"
45
}
56

67
kotlin {

gradle-plugins/compose/src/test/test-projects/beforeKotlin2/jsMpp/settings.gradle renamed to gradle-plugins/compose/src/test/test-projects/application/jsMpp/settings.gradle

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
pluginManagement {
22
plugins {
33
id 'org.jetbrains.kotlin.multiplatform' version 'KOTLIN_VERSION_PLACEHOLDER'
4+
id 'org.jetbrains.kotlin.plugin.compose' version 'KOTLIN_VERSION_PLACEHOLDER'
45
id 'org.jetbrains.compose' version 'COMPOSE_GRADLE_PLUGIN_VERSION_PLACEHOLDER'
56
}
67
repositories {
File renamed without changes.
File renamed without changes.
File renamed without changes.

gradle-plugins/compose/src/test/test-projects/beforeKotlin2/custom-compiler-args/build.gradle

Lines changed: 0 additions & 50 deletions
This file was deleted.
-137 Bytes
Binary file not shown.

gradle-plugins/compose/src/test/test-projects/beforeKotlin2/custom-compiler-args/settings.gradle

Lines changed: 0 additions & 26 deletions
This file was deleted.

0 commit comments

Comments
 (0)