GitHunt
KA

Kantis/kotlin-js-wasm-testing

Experimental Kotlin/JS and Kotlin/Wasm/JS test infrastructure

Experimental Kotlin/JS and Kotlin/Wasm/JS test infrastructure

This project aims to experiment with test runners on the JS platform, in particular regarding

  • supporting asynchronous tests,
  • supporting nested tests.

The project features alternative test frameworks, selectable by setting testFramework in src/jsHostedMain/kotlin/Main.kt:

  • kotlinJsTestFramework: A bare-bones implementation of the Kotlin-provided test framework used with kotlin-test.
  • standaloneJsTestFramework: A standalone test runner. The initial version supports flat tests only. It does not work with browser-based tests.

Synchronous and asynchronous test invocations are supported.

Test Tasks

  • gradlew --continue cleanAllTests jsBrowserTest jsNodeTest wasmJsBrowserTest wasmJsNodeTest

  • gradlew cleanJsBrowserTest jsBrowserTest

  • gradlew cleanWasmJsNodeTest wasmJsNodeTest

  • gradlew cleanJsNodeTest jsNodeTest

  • gradlew cleanWasmJsBrowserTest wasmJsBrowserTest

Checking unmodified test reports

Available with the standaloneJsTestFramework only.

  • gradlew jsNodeDevelopmentRun

Background

Languages

Kotlin100.0%

Contributors

Apache License 2.0
Created March 31, 2024
Updated March 31, 2024