Functions

f
openSession(
input?: SessionOptions | string | string[],
extra?: SessionOptions
): Task<TestSession | WatchSession, RunFailure>
4 overloads

With watch: true, the DURABLE shape: one page behind a stable WatchSession.url, kept open with the rerun verbs and file watching, exactly as watch gives you.

Interfaces

I
TestSession

One run, watched as it happens.

  • abort(): Promise<void>

    Cuts the run short. The browser drops the rest of its queue and the run ends where it is, with aborted: true on the result — which TestSession.result still resolves with, so an aborted run is answered rather than left hanging.

  • close(): Promise<void>

    Closes the session, ending iteration. Idempotent; implied by await using.

  • droppedEvents: number

    How many events the feed dropped because a consumer fell behind. 0 in every ordinary run.

  • events(): Stream<RunEvent>

    The same events as iterating the session, as a Stream — so the combinators are there without a Stream.from wrapper.

  • result(): Promise<RunResult>

    The finished run. Starts it if nothing has yet, and resolves with the same RunResult the final runEnd event carries — never undefined, which is the whole reason this is a session rather than a bare event stream.

Type Aliases

T
SessionOptions = UserRunOptions & { watch?: boolean; }

What openSession accepts: every run option, plus the one that chooses the shape.