[K/N][test] Add test for ^KT-58537

This commit is contained in:
Pavel Punegov
2023-06-01 12:41:36 +02:00
committed by Space Team
parent 47c7dfe6b4
commit d81084f66f
8 changed files with 72 additions and 0 deletions
@@ -1189,6 +1189,17 @@ class GeneralNativeIT : BaseGradleIT() {
}
}
// KT-58537
@Test
@Ignore("Requires update to the newer version with changes")
fun testProjectNameWithSpaces() = with(transformNativeTestProjectWithPluginDsl("native-root-project-name-with-space")) {
build("assemble") {
assertNotContains("Could not find \"Contains\" in")
assertSuccessful()
}
}
companion object {
fun List<String>.containsSequentially(vararg elements: String): Boolean {
check(elements.isNotEmpty())
@@ -0,0 +1,10 @@
plugins {
kotlin("multiplatform").version("<pluginMarkerVersion>").apply(false)
}
allprojects {
repositories {
mavenCentral()
mavenLocal()
}
}
@@ -0,0 +1,21 @@
plugins {
kotlin("multiplatform")
}
kotlin {
<SingleNativeTarget>("host") {
binaries {
sharedLib {
baseName = "shared"
}
}
}
sourceSets {
val commonMain by getting {
dependencies {
implementation(project(":module2"))
}
}
}
}
@@ -0,0 +1,8 @@
/*
* 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.
*/
fun module1() {
}
@@ -0,0 +1,11 @@
plugins {
kotlin("multiplatform")
}
kotlin {
<SingleNativeTarget>("host")
sourceSets {
val commonMain by getting
}
}
@@ -0,0 +1,8 @@
/*
* 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.
*/
fun module2() {
println("module2/src/commonMain/kotlin/Module2.kt")
}
@@ -0,0 +1,3 @@
rootProject.name = "Contains Space"
include(":module1")
include(":module2")