TestProgressSessionController

Drives a TestProgressSession state and progress in tests.

Use setState, succeed, fail, or cancel to force transitions directly. Scripted transitions configured via TestSessionScript are applied when the session methods are invoked, including via await() or Session.TerminalStateListener.bind.

Properties

Link copied to clipboard

Number of times Session.cancel has been invoked.

Link copied to clipboard

Number of times Session.commit has been invoked.

Link copied to clipboard

Number of times Session.launch has been invoked.

Link copied to clipboard

Scripted transitions used to drive session state updates in tests.

Functions

Link copied to clipboard
open override fun cancel(): TestProgressSessionController<F>

Marks the session as cancelled.

Link copied to clipboard
open override fun fail(failure: F): TestProgressSessionController<F>

Marks the session as failed with the provided failure.

Link copied to clipboard

Resets launch/commit/cancel invocation counters.

Link copied to clipboard
open override fun setProgress(progress: Progress): TestProgressSessionController<F>

Updates session progress.

Link copied to clipboard

Sets the current state of the session.

Link copied to clipboard

Marks the session as succeeded.