Browse Source

Test runDistributable with MPP project (#436)

pull/443/head
Alexey Tsvetkov 4 years ago committed by GitHub
parent
commit
d68cb7b68b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 14
      gradle-plugins/compose/src/test/kotlin/org/jetbrains/compose/DesktopApplicationTest.kt
  2. 4
      gradle-plugins/compose/src/test/test-projects/application/mpp/src/jvmMain/kotlin/main.kt

14
gradle-plugins/compose/src/test/kotlin/org/jetbrains/compose/DesktopApplicationTest.kt

@ -35,6 +35,20 @@ class DesktopApplicationTest : GradlePluginTestBase() {
}
}
@Test
fun testRunMpp() = with(testProject(TestProjects.mpp)) {
val logLine = "Kotlin MPP app is running!"
gradle("run").build().checks { check ->
check.taskOutcome(":run", TaskOutcome.SUCCESS)
check.logContains(logLine)
}
gradle("runDistributable").build().checks { check ->
check.taskOutcome(":createDistributable", TaskOutcome.SUCCESS)
check.taskOutcome(":runDistributable", TaskOutcome.SUCCESS)
check.logContains(logLine)
}
}
@Test
fun kotlinDsl(): Unit = with(testProject(TestProjects.jvmKotlinDsl)) {
gradle(":package", "--dry-run").build()

4
gradle-plugins/compose/src/test/test-projects/application/mpp/src/jvmMain/kotlin/main.kt

@ -1 +1,3 @@
fun main() {}
fun main() {
println("Kotlin MPP app is running!")
}
Loading…
Cancel
Save