Skip to content

Application

Navigate and inspect your app from a test. Tests have their own context and read the app DOM directly. Fresh documents don’t reset browser storage or backend data.

Property Modifier Type Description
document readonly Document Read the current app document after navigation is ready. Resolve elements again after navigation.
native readonly NativeBrowser Use managed browser features such as native input and permissions. Required operations fail when unsupported.
window readonly Window & typeof globalThis Read the current app window. Browser APIs are available directly; use Interactor assertions for changing state.

fixture<T = unknown>(name: string, input?: unknown): Promise<T>

Call a named fixture in this worker’s actual app process. Dyno supplies the execution capability, bounded JSON, cancellation, and a named timing step. Configure the optional fixture controller through beforeExecution. Omitted input is null. Calls never retry or follow redirects; abort cannot undo a committed write. Await every call before finishing the test or hook.

Type Parameter Default type
T unknown
Parameter Type
name string
input? unknown

Promise<T>


goto(path: string): Promise<void>

Navigate to a same-origin app path and wait for its document bridge. Then use Interactor to wait for the UI you care about.

Parameter Type
path string

Promise<void>


pause(message?: string): Promise<void>

Open the reporter and suspend the execution deadline until Continue. Requires --ui or --manual. App timers and network work keep running; cleanup cannot pause.

Parameter Type
message? string

Promise<void>


request(path: string, options?: RequestInit): Promise<Response>

Fetch options pass through, including credentials: 'omit' for API setup that should not change the browser session. Same-origin cookies are included by default. Dyno owns the cancellation signal.

Fetch a same-origin URL using the browser session and test cancellation signal. Returns a standard Response. Use this for your app’s test-only fixture endpoints; keep database factories in your project.

Parameter Type
path string
options? RequestInit

Promise<Response>


screenshot(name: string, options?: ScreenshotOptions): Promise<Screenshot>

Save an exact PNG of the app, excluding the reporter. Full-page and element captures are supported. Required capture fails when unavailable; explicitly optional capture can skip.

Parameter Type
name string
options? ScreenshotOptions

Promise<Screenshot>


setViewport(viewport: Viewport): Promise<Viewport>

Resize the actual managed viewport and wait for layout. Each dimension must be 1–16384 CSS pixels. Manual runs require the requested dimensions to already match.

Parameter Type
viewport Viewport

Promise<Viewport>