Skip to content

Commit 80f1d6b

Browse files
committed
Update tests
1 parent 2f44453 commit 80f1d6b

File tree

5 files changed

+31
-2265
lines changed

5 files changed

+31
-2265
lines changed

build-logic/src/main/kotlin/kotlinx/io/conventions/kotlinx-io-multiplatform.gradle.kts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,8 @@ kotlin {
4040
@OptIn(org.jetbrains.kotlin.gradle.targets.js.dsl.ExperimentalWasmDsl::class)
4141
wasm {
4242
nodejs()
43-
browser()
43+
// Disabled because we can't exclude some tests: https://youtrack.jetbrains.com/issue/KT-58291
44+
// browser()
4445
binaries.executable()
4546
}
4647

core/build.gradle.kts

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,18 @@ kotlin {
3030
}
3131
}
3232

33+
@OptIn(org.jetbrains.kotlin.gradle.targets.js.dsl.ExperimentalWasmDsl::class)
34+
wasm {
35+
nodejs {
36+
testTask(Action {
37+
useMocha {
38+
timeout = "300s"
39+
}
40+
filter.setExcludePatterns("*SmokeFileTest*")
41+
})
42+
}
43+
}
44+
3345
sourceSets {
3446
commonMain {
3547
dependencies {

core/wasm/src/files/PathsWasm.kt

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,8 @@
55

66
package kotlinx.io.files
77

8-
import kotlinx.io.*
8+
import kotlinx.io.Sink
9+
import kotlinx.io.Source
910

1011

1112
public actual class Path internal constructor(private val path: String,
@@ -18,9 +19,9 @@ public actual fun Path(path: String): Path {
1819
}
1920

2021
public actual fun Path.source(): Source {
21-
TODO()
22+
TODO("Paths are not supported for Wasm target")
2223
}
2324

2425
public actual fun Path.sink(): Sink {
25-
TODO()
26+
TODO("Paths are not supported for Wasm target")
2627
}

core/wasm/test/utils.kt

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -5,13 +5,10 @@
55

66
package kotlinx.io
77

8-
import kotlin.random.Random
9-
import kotlin.random.nextULong
10-
118
actual fun createTempFile(): String {
12-
TODO()
9+
TODO("Paths are not supported for Wasm target")
1310
}
1411

1512
actual fun deleteFile(path: String) {
16-
TODO()
13+
TODO("Paths are not supported for Wasm target")
1714
}

0 commit comments

Comments
 (0)