-
Notifications
You must be signed in to change notification settings - Fork 5.8k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
KAPT3: Use another class in com.sun.tools.javac.main
Instead of CommandLine use Option, since CommandLine was moved or removed from JDK 21. #KT-60507 Fixed
- Loading branch information
Showing
4 changed files
with
63 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
25 changes: 25 additions & 0 deletions
25
...n-integration-tests/src/test/kotlin/org/jetbrains/kotlin/gradle/testbase/jdkConditions.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
/* | ||
* Copyright 2010-2023 JetBrains s.r.o. and Kotlin Programming Language contributors. | ||
* Use of this source code is governed by the Apache 2.0 license that can be found in the license/LICENSE.txt file. | ||
*/ | ||
|
||
package org.jetbrains.kotlin.gradle.testbase | ||
|
||
import org.junit.jupiter.api.extension.ConditionEvaluationResult | ||
import org.junit.jupiter.api.extension.ExecutionCondition | ||
import org.junit.jupiter.api.extension.ExtendWith | ||
import org.junit.jupiter.api.extension.ExtensionContext | ||
|
||
class EnableOnJdk21Condition : ExecutionCondition { | ||
override fun evaluateExecutionCondition(context: ExtensionContext?): ConditionEvaluationResult = | ||
if (System.getProperty("jdk21Home") == null) { | ||
ConditionEvaluationResult.disabled("No JDK 21 Found") | ||
} else { | ||
ConditionEvaluationResult.enabled("JDK 21 Found") | ||
} | ||
} | ||
|
||
@Target(AnnotationTarget.FUNCTION) | ||
@Retention(AnnotationRetention.RUNTIME) | ||
@ExtendWith(EnableOnJdk21Condition::class) | ||
annotation class EnableOnJdk21 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters