Skip to content

Commit f95bdb4

Browse files
committed
Enable wasm compatibility tests
1 parent f131756 commit f95bdb4

File tree

4 files changed

+4
-12
lines changed

4 files changed

+4
-12
lines changed

.github/workflows/run-tests-compatibility.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,8 @@ jobs:
2020
os: [ 'ubuntu-latest' ]
2121
target: [ 'jvm', 'js', 'native' ]
2222
include:
23+
- os: 'macos-latest'
24+
target: 'wasm'
2325
- os: 'macos-latest'
2426
target: 'macos'
2527
- os: 'windows-latest'
@@ -68,6 +70,8 @@ jobs:
6870
os: [ 'ubuntu-latest' ]
6971
target: [ 'jvm', 'js', 'native' ]
7072
include:
73+
- os: 'macos-latest'
74+
target: 'wasm'
7175
- os: 'macos-latest'
7276
target: 'macos'
7377
- os: 'windows-latest'

cryptography-providers-tests-api/src/commonMain/kotlin/compatibility/CompatibilityTest.kt

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,21 +15,18 @@ abstract class CompatibilityTest<A : CryptographyAlgorithm>(
1515
abstract suspend fun CompatibilityTestScope<A>.generate(isStressTest: Boolean)
1616
abstract suspend fun CompatibilityTestScope<A>.validate()
1717

18-
@WasmIgnore
1918
@Test
2019
fun generateStep() = testWithAlgorithm {
2120
val logger = logger.child("GENERATE")
2221
runCompatibilityTestStep(logger, ServerApi(algorithmId.name, context, logger)) { generate(isStressTest = false) }
2322
}
2423

25-
@WasmIgnore
2624
@Test
2725
fun generateStressStep() = testWithAlgorithm {
2826
val logger = logger.child("GENERATE")
2927
runCompatibilityTestStep(logger, ServerApi(algorithmId.name, context, logger)) { generate(isStressTest = true) }
3028
}
3129

32-
@WasmIgnore
3330
@Test
3431
fun validateStep() = testWithAlgorithm {
3532
val logger = logger.child("VALIDATE")

cryptography-providers-tests-api/src/commonMain/kotlin/utils.kt

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -71,8 +71,3 @@ fun Buffer.bufferedSource(): Source = (this as RawSource).buffered()
7171
fun Buffer.bufferedSink(): Sink = (this as RawSink).buffered()
7272

7373
expect fun disableJsConsoleDebug()
74-
75-
// Wasm tests on browser cannot be filtered: https://youtrack.jetbrains.com/issue/KT-58291
76-
@OptIn(ExperimentalMultiplatform::class)
77-
@OptionalExpectation
78-
expect annotation class WasmIgnore()

cryptography-providers-tests-api/src/wasmJsMain/kotlin/TestPlatform.wasmJs.kt

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,6 @@
44

55
package dev.whyoleg.cryptography.providers.tests.api
66

7-
import kotlin.test.*
8-
9-
actual typealias WasmIgnore = Ignore
10-
117
internal actual val currentTestPlatform: TestPlatform = jsPlatform().run {
128
when {
139
isNode -> TestPlatform.WasmJs.NodeJS(

0 commit comments

Comments
 (0)