Skip to content

Commit 29ce41f

Browse files
committed
Update jvmTarget and language version in projects
1 parent 3eb782e commit 29ce41f

File tree

3 files changed

+7
-10
lines changed

3 files changed

+7
-10
lines changed

integration-tests/src/test/kotlin/com/google/devtools/ksp/test/AndroidIncrementalIT.kt

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -30,11 +30,10 @@ class AndroidIncrementalIT() {
3030
@JvmField
3131
val project: TemporaryTestProject = TemporaryTestProject("playground-android-multi", "playground")
3232

33-
private fun testWithExtraFlags(vararg extras: String) {
33+
private fun testWithExtraFlags() {
3434
val gradleRunner = GradleRunner.create().withProjectDir(project.root)
3535

3636
gradleRunner.withArguments(
37-
*extras,
3837
"clean", ":application:compileDebugKotlin", "--configuration-cache-problems=warn", "--debug", "--stacktrace"
3938
).build().let { result ->
4039
Assert.assertEquals(TaskOutcome.SUCCESS, result.task(":workload:compileDebugKotlin")?.outcome)
@@ -51,7 +50,6 @@ class AndroidIncrementalIT() {
5150
}
5251

5352
gradleRunner.withArguments(
54-
*extras,
5553
":application:compileDebugKotlin", "--configuration-cache-problems=warn", "--debug", "--stacktrace"
5654
).build().let { result ->
5755
Assert.assertEquals(

integration-tests/src/test/kotlin/com/google/devtools/ksp/test/PlaygroundIT.kt

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ class PlaygroundIT() {
5656
"""
5757
kotlin {
5858
compilerOptions {
59-
jvmTarget.set(org.jetbrains.kotlin.gradle.dsl.JvmTarget.JVM_1_8)
59+
jvmTarget.set(org.jetbrains.kotlin.gradle.dsl.JvmTarget.JVM_9)
6060
}
6161
}
6262
""".trimIndent()
@@ -65,7 +65,7 @@ class PlaygroundIT() {
6565
"""
6666
kotlin {
6767
compilerOptions {
68-
jvmTarget.set(org.jetbrains.kotlin.gradle.dsl.JvmTarget.JVM_1_8)
68+
jvmTarget.set(org.jetbrains.kotlin.gradle.dsl.JvmTarget.JVM_9)
6969
}
7070
}
7171
""".trimIndent()
@@ -247,18 +247,17 @@ class PlaygroundIT() {
247247
"""
248248
kotlin {
249249
compilerOptions {
250-
apiVersion.set(org.jetbrains.kotlin.gradle.dsl.KotlinVersion.KOTLIN_1_8)
250+
apiVersion.set(org.jetbrains.kotlin.gradle.dsl.KotlinVersion.KOTLIN_1_9)
251251
languageVersion.set(compilerOptions.apiVersion)
252252
}
253253
}
254254
""".trimIndent()
255255
)
256256

257-
val kotlinVersion = System.getProperty("kotlinVersion").split('-').first()
258257
val gradleRunner = GradleRunner.create().withProjectDir(project.root)
259258
gradleRunner.buildAndCheck("clean", "build") { result ->
260-
Assert.assertTrue(result.output.contains("language version: 1.8"))
261-
Assert.assertTrue(result.output.contains("api version: 1.8"))
259+
Assert.assertTrue(result.output.contains("language version: 1.9"))
260+
Assert.assertTrue(result.output.contains("api version: 1.9"))
262261
val expectedKspVersion = "2.0"
263262
Assert.assertTrue(result.output.contains("ksp version: $expectedKspVersion"))
264263
}

integration-tests/src/test/kotlin/com/google/devtools/ksp/test/fixtures/BuildResultFixture.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ package com.google.devtools.ksp.test.fixtures
1919

2020
import org.gradle.testkit.runner.BuildResult
2121

22-
private val compileKotlinSrcs = Regex("\\[KOTLIN\\] compile iteration: ([^\\r\\n]*)")
22+
private val compileKotlinSrcs = Regex("\\[KOTLIN\\] v: compile iteration: ([^\\r\\n]*)")
2323

2424
class BuildResultFixture(private val result: BuildResult) {
2525

0 commit comments

Comments
 (0)