Package-level declarations

Properties

Link copied to clipboard
Link copied to clipboard

The path to the "tests" directory. This assumes all tests are run from a predictable place relative to "tests" We need this for JS tests where the CWD is not properly set at the beginning of tests

The path to the "tests" directory. This assumes all tests are run from a predictable place relative to "tests" We need this for JS tests where the CWD is not properly set at the beginning of tests

Functions

Link copied to clipboard
Link copied to clipboard

Extracts the operationId from a graphql-ws message, ignores "complete messages"

Link copied to clipboard
suspend fun <T> Channel<T>.awaitElement(timeoutMillis: Long = 30000): T
Link copied to clipboard

Extracts the operationId from a graphql-ws message

Link copied to clipboard

Checks that actualText matches the contents of the file at path

Link copied to clipboard
fun cwd(): String
Link copied to clipboard
fun <D : Operation.Data> MockServer.enqueue(operation: Operation<D>, data: D, customScalarAdapters: CustomScalarAdapters = CustomScalarAdapters.Empty, delayMs: Long = 0)
Link copied to clipboard
fun MockServer.enqueueData(data: Operation.Data, customScalarAdapters: CustomScalarAdapters = CustomScalarAdapters.Empty, delayMillis: Long = 0, statusCode: Int = 200)
fun MockServer.enqueueData(data: Map<String, Any?>, customScalarAdapters: CustomScalarAdapters = CustomScalarAdapters.Empty, delayMillis: Long = 0, statusCode: Int = 200)
Link copied to clipboard

A convenience function that makes sure the MockServer and ApolloClient are properly closed at the end of the test

Link copied to clipboard

The current platform. This is used from tests because Double.toString() doesn't behave the same on JS and other platforms. Prefer more specific functions like assertMainThreadOnNative when possible instead of checking the platform.

The current platform. This is used from tests because Double.toString() doesn't behave the same on JS and other platforms. Prefer more specific functions like assertMainThreadOnNative when possible instead of checking the platform.

The current platform. This is used from tests because Double.toString() doesn't behave the same on JS and other platforms. Prefer more specific functions like assertMainThreadOnNative when possible instead of checking the platform.

The current platform. This is used from tests because Double.toString() doesn't behave the same on JS and other platforms. Prefer more specific functions like assertMainThreadOnNative when possible instead of checking the platform.

The current platform. This is used from tests because Double.toString() doesn't behave the same on JS and other platforms. Prefer more specific functions like assertMainThreadOnNative when possible instead of checking the platform.

Link copied to clipboard