Skip to content

Commit ec73f40

Browse files
TapchicomaSpace
authored and
Space
committed
Fix Gradle plugin inputs validation issue
Also add '@internal' annotation in interface, so it propagated to all inheritors. ^KT-52448 Fixed
1 parent 5f3b1e3 commit ec73f40

File tree

2 files changed

+23
-0
lines changed
  • libraries/tools

2 files changed

+23
-0
lines changed

libraries/tools/kotlin-gradle-plugin-api/src/common/kotlin/org/jetbrains/kotlin/gradle/tasks/KotlinTaskConfigs.kt

+6
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,12 @@ interface KotlinCompileTool : PatternFilterable, Task {
4343

4444
@get:OutputDirectory
4545
val destinationDirectory: DirectoryProperty
46+
47+
@Internal
48+
override fun getExcludes(): MutableSet<String>
49+
50+
@Internal
51+
override fun getIncludes(): MutableSet<String>
4652
}
4753

4854
interface BaseKotlinCompile : KotlinCompileTool {

libraries/tools/kotlin-gradle-plugin-integration-tests/src/test/kotlin/org/jetbrains/kotlin/gradle/SimpleKotlinGradleIT.kt

+17
Original file line numberDiff line numberDiff line change
@@ -226,4 +226,21 @@ class SimpleKotlinGradleIT : KGPBaseTest() {
226226
}
227227
}
228228
}
229+
230+
@DisplayName("Validate Gradle plugins inputs")
231+
@GradleTestVersions(minVersion = TestVersions.Gradle.MAX_SUPPORTED) // Always should use only latest Gradle version
232+
@GradleTest
233+
internal fun validatePluginInputs(gradleVersion: GradleVersion) {
234+
project("kotlinProject", gradleVersion) {
235+
buildGradle.modify {
236+
"""
237+
plugins {
238+
id "validate-external-gradle-plugin"
239+
${it.substringAfter("plugins {")}
240+
""".trimIndent()
241+
}
242+
243+
build("validateExternalPlugins")
244+
}
245+
}
229246
}

0 commit comments

Comments
 (0)