[Gradle, tests] Fix native compiler arguments test for Windows
This commit is contained in:
+8
-1
@@ -2525,7 +2525,14 @@ class NewMultiplatformIT : BaseGradleIT() {
|
|||||||
@Test
|
@Test
|
||||||
fun testNativeArgsWithSpaces() = with(Project("sample-lib", directoryPrefix = "new-mpp-lib-and-app")) {
|
fun testNativeArgsWithSpaces() = with(Project("sample-lib", directoryPrefix = "new-mpp-lib-and-app")) {
|
||||||
setupWorkingDir()
|
setupWorkingDir()
|
||||||
val fileWithSpacesInPath = projectDir.resolve("src/commonMain/kotlin/path with spaces and special symbols like \"")
|
val compilcatedDirectoryName = if (HostManager.hostIsMingw) {
|
||||||
|
// Windows doesn't allow creating a file with " in its name.
|
||||||
|
"path with spaces"
|
||||||
|
} else {
|
||||||
|
"path with spaces and \""
|
||||||
|
}
|
||||||
|
|
||||||
|
val fileWithSpacesInPath = projectDir.resolve("src/commonMain/kotlin/$compilcatedDirectoryName")
|
||||||
.apply { mkdirs() }
|
.apply { mkdirs() }
|
||||||
.resolve("B.kt")
|
.resolve("B.kt")
|
||||||
fileWithSpacesInPath.writeText("fun foo() = 42")
|
fileWithSpacesInPath.writeText("fun foo() = 42")
|
||||||
|
|||||||
Reference in New Issue
Block a user