Package-level declarations

Multiplatform test drivers and session management for Android, iOS, Desktop, and Wasm.

Multiplatform test drivers and session management for Android, iOS, Desktop, and Wasm.

Multiplatform test drivers and session management for Android, iOS, Desktop, and Wasm.

Multiplatform test drivers and session management for Android, iOS, Desktop, and Wasm.

Multiplatform test drivers and session management for Android, iOS, Desktop, and Wasm.

Types

Link copied to clipboard
Link copied to clipboard

JVM-side driver that communicates with the ParikshanAndroidServer running inside the real Android app on the emulator/device. Uses HTTP POST over an adb forwarded port (e.g. 9879).

Link copied to clipboard
class DesktopDriver(host: String = "127.0.0.1", port: Int = 9877, sessionToken: String = System.getProperty("parikshan.token") ?: "") : TestDriver

JVM-side driver that talks to the Parikshan server running inside a Desktop app.

Link copied to clipboard
data class IosDriverConfig(val host: String = "127.0.0.1", val port: Int = 9878)
Link copied to clipboard
class IosE2ETestScope(defaultWaitTimeoutMs: Long, commandDelayMs: Long = 0, failureScreenshotPath: String = "build/parikshan/failures/failure-", captureScreenshotOnFailure: Boolean = true)

Synchronous iOS E2E test scope that drives waits via NSRunLoop pumping instead of coroutine delay. This keeps the main thread available for UIKit/Compose rendering between polls.

Link copied to clipboard

JVM-side driver that talks to the Parikshan server running inside the iOS app.

Link copied to clipboard

Generic instrumentation test runner for Parikshan. The Gradle plugin will execute this test class via adb shell am instrument. It launches the user's default app activity, starts the in-app HTTP server, and passes the ComposeTestRule to it so it can execute remote E2E commands.

Link copied to clipboard

JVM-side driver for Compose/Wasm. It opens the app in Playwright and invokes the in-browser Parikshan bridge installed by Modifier.testTag instrumentation.

Functions

Link copied to clipboard
actual fun e2eTest(config: E2ETestConfig, block: suspend E2ETestScope.() -> Unit)

The primary entry point for writing End-to-End tests in Parikshan.

fun e2eTest(composeUiTest: AndroidComposeTestRule<*, *>, config: E2ETestConfig = E2ETestConfig(), block: suspend E2ETestScope.() -> Unit)
expect fun e2eTest(config: E2ETestConfig = E2ETestConfig(), block: suspend E2ETestScope.() -> Unit)

The primary entry point for writing End-to-End tests in Parikshan.

actual fun e2eTest(config: E2ETestConfig, block: suspend E2ETestScope.() -> Unit)

The primary entry point for writing End-to-End tests in Parikshan.

actual fun e2eTest(config: E2ETestConfig, block: suspend E2ETestScope.() -> Unit)

The primary entry point for writing End-to-End tests in Parikshan.

actual fun e2eTest(config: E2ETestConfig, block: suspend E2ETestScope.() -> Unit)

The primary entry point for writing End-to-End tests in Parikshan.

Link copied to clipboard

Initializes the Parikshan bridge for Wasm.

Link copied to clipboard
fun iosE2ETest(defaultWaitTimeoutMs: Long, commandDelayMs: Long = 300, block: IosE2ETestScope.() -> Unit)

Runs an iOS E2E test block synchronously on the main thread, using NSRunLoop pumping for Compose recomposition.

Link copied to clipboard
fun Modifier.parikshanBridge(tag: String, text: String? = null, visible: Boolean = true, onClick: () -> Unit? = null, onInput: (String) -> Unit? = null, onScroll: (ScrollDirection) -> Unit? = null, scrollState: ScrollState? = null): Modifier

Compatibility bridge for targets that still need app-side Parikshan metadata/actions alongside the stable selector contract provided by Modifier.testTag.

Link copied to clipboard
fun ParikshanComposeViewport(viewportContainer: HTMLElement, content: @Composable () -> Unit)

Replaces ComposeViewport to automatically grab the SemanticsOwner for E2E testing in Wasm.

Link copied to clipboard
fun ParikshanUIViewController(content: @Composable () -> Unit): UIViewController

Replaces ComposeUIViewController to automatically start the Parikshan in-app HTTP server and grab the SemanticsOwner for E2E testing.

Link copied to clipboard
fun pumpRunLoop(iterations: Int = 5, intervalSeconds: Double = 0.05)

Pumps the NSRunLoop to allow UIKit and Compose to process pending layout, rendering, and recomposition work.

Link copied to clipboard

Clears all tracked nodes from the iOS bridge state. Call between tests to prevent stale node interference.