aboutsummaryrefslogtreecommitdiff
path: root/runners/gradle-plugin/src/test/kotlin
diff options
context:
space:
mode:
authorsebastian.sellmair <sebastian.sellmair@jetbrains.com>2020-07-10 10:56:50 +0200
committerSebastian Sellmair <34319766+sellmair@users.noreply.github.com>2020-07-13 14:23:08 +0200
commitc3eeb211bc51e19e1dc76c2fad4993bcf4999f5d (patch)
tree25eb536ef4384bb95c8da7d8655d0ef1419171a8 /runners/gradle-plugin/src/test/kotlin
parent171f7faed806c9c744d16cf6fafa10f0edcc69b4 (diff)
downloaddokka-c3eeb211bc51e19e1dc76c2fad4993bcf4999f5d.tar.gz
dokka-c3eeb211bc51e19e1dc76c2fad4993bcf4999f5d.tar.bz2
dokka-c3eeb211bc51e19e1dc76c2fad4993bcf4999f5d.zip
Implement `AbstractDokkaTask` to suport DokkaMultimoduleTask
Diffstat (limited to 'runners/gradle-plugin/src/test/kotlin')
-rw-r--r--runners/gradle-plugin/src/test/kotlin/org/jetbrains/dokka/gradle/KotlinDslDokkaTaskConfigurationTest.kt12
1 files changed, 7 insertions, 5 deletions
diff --git a/runners/gradle-plugin/src/test/kotlin/org/jetbrains/dokka/gradle/KotlinDslDokkaTaskConfigurationTest.kt b/runners/gradle-plugin/src/test/kotlin/org/jetbrains/dokka/gradle/KotlinDslDokkaTaskConfigurationTest.kt
index 3ba5602f..b4b54957 100644
--- a/runners/gradle-plugin/src/test/kotlin/org/jetbrains/dokka/gradle/KotlinDslDokkaTaskConfigurationTest.kt
+++ b/runners/gradle-plugin/src/test/kotlin/org/jetbrains/dokka/gradle/KotlinDslDokkaTaskConfigurationTest.kt
@@ -13,7 +13,9 @@ class KotlinDslDokkaTaskConfigurationTest {
fun `configure project using dokka extension function`() {
val project = ProjectBuilder.builder().build()
project.plugins.apply("org.jetbrains.dokka")
- project.dokka { this.outputDirectory = "test" }
+ project.tasks.withType(DokkaTask::class.java).forEach { dokkaTask ->
+ dokkaTask.outputDirectory = "test"
+ }
project.tasks.withType(DokkaTask::class.java).forEach { dokkaTask ->
assertEquals("test", dokkaTask.outputDirectory)
@@ -25,8 +27,8 @@ class KotlinDslDokkaTaskConfigurationTest {
val project = ProjectBuilder.builder().build()
project.plugins.apply("org.jetbrains.dokka")
- project.dokka {
- dokkaSourceSets.run {
+ project.tasks.withType(DokkaTask::class.java).forEach { dokkaTask ->
+ dokkaTask.dokkaSourceSets.run {
val commonMain = create("commonMain")
val jvmMain = create("jvmMain") {
it.dependsOn("commonMain")
@@ -59,7 +61,7 @@ class KotlinDslDokkaTaskConfigurationTest {
val project = ProjectBuilder.builder().build()
project.plugins.apply("org.jetbrains.dokka")
- project.dokka {
+ project.tasks.withType(DokkaTask::class.java).first().run {
dokkaSourceSets.run {
val commonMain = create("commonMain")
val jvmMain = create("jvmMain") {
@@ -81,7 +83,7 @@ class KotlinDslDokkaTaskConfigurationTest {
val kotlin = project.extensions.getByName("kotlin") as KotlinJvmProjectExtension
- project.dokka {
+ project.tasks.withType(DokkaTask::class.java).first().run {
dokkaSourceSets.run {
val special = create("special") {
it.dependsOn(kotlin.sourceSets.getByName("main"))