Skip to navigation

Resolved context

Referenced In

Fields

FieldTypeDescriptionDefault
resultstringReadOnly. Outcome of this context. Doc Detective populates it. You never set it yourself.

Accepted values: PASS, FAIL, WARNING, SKIPPED
—
resultDescriptionstringReadOnly. Why this context had its outcome. Doc Detective populates it. You never set it yourself.—
durationMsintegerReadOnly. Wall-clock duration of this context in milliseconds, covering preflight, driver startup, every step, and teardown. When the retries policy re-ran the context, this is the FINAL attempt’s elapsed time — the attempt the reported result describes — not the sum across attempts. Present only in test results. System-populated.

Minimum: 0
—
startedAtstringReadOnly. When this context started, as an ISO 8601 UTC timestamp with milliseconds. When the retries policy re-ran the context, this is the start of the FINAL attempt — the attempt the reported result describes — matching durationMs. Absent for a context that never ran, such as one a spec-level guard skipped. Present only in test results. System-populated.—
driverobject(Driver)ReadOnly. The WebDriver that drove this context’s browser, as the browser session reported it. Absent when no browser ran. Present only in test results. System-populated.—
autoRecordingobject(Automatic recording)ReadOnly. The video autoRecord made of this context. Absent when no automatic recording was attempted, including when autoRecord is unset and the run’s recording check failed. Present only in test results. System-populated.—
platformstringOptional. Platform to run the test on. This is a resolved version of the platforms property.—
browserobject(Browser)Optional. Browser configuration.—
openApiarray of unknownOptional. No description provided.—
stepsarray of object(step)Optional. Steps to perform as part of the test. Performed in the sequence defined. If one or more actions fail, the test fails. By default, if a step fails, the test stops and the remaining steps are not executed. In test results, a context that never ran, such as a skipped one, has an empty list.—
contextIdstringOptional. Unique ID of this context within its test. Doc Detective derives it from the platform and browser, such as linux-chrome, unless the runOn entry sets one.—
unsafebooleanReadOnly. Whether this context’s test is marked unsafe. Present in a resolved test plan. System-populated.—
requiresone of:
- string
- array of string
- object(Requirements)
Optional. Capabilities the environment must provide for this context to run. A string names a required command; an array names several; the object form checks commands (on PATH), files (paths, with $VAR/$HOME expansion), and environment variables. All entries are AND-ed. Any unmet requirement marks the context as SKIPPED — the same non-failing outcome as a platforms mismatch.—
browserFallbackstringOptional. Per-context override for the config-level browserFallback policy that governs whether a context whose browser can’t start a driver session falls back to another available browser. Accepts the same values — auto, explicit, off — and, when set, takes precedence over the config-level value for the contexts this entry expands into. Omit it to inherit the config-level policy (which itself defaults to auto).

Accepted values: auto, explicit, off
—
retriesintegerOptional. In a resolved test plan, the retries policy from the runOn entry. In test results, how many times the context re-ran on a fresh session after its session died. Absent from results when it didn’t re-run.

Minimum: 0
—
devicestring or objectOptional. The device a mobile (android or ios) context runs on. In a resolved test plan, the device from the runOn entry. In test results, an object with the device’s platform and name. Absent for a desktop context.—
warningsarray of stringReadOnly. Warnings from this context’s preflight checks, such as a toolchain that Doc Detective had to install first. Present only in test results, when there are any. System-populated.—
fallbackobjectReadOnly. The browser this context asked for, and the one that ran instead because browserFallback allowed it. Present only in test results, when a fallback happened. System-populated.—
viewportFlooredbooleanReadOnly. true when the browser couldn’t shrink to the requested viewport and stopped at its smallest size. Present only in test results, when that happened. System-populated.—

Examples

{
"platform": "example",
"browser": {
"name": "chrome"
},
"openApi": [],
"steps": [],
"contextId": "example",
"requires": "example",
"browserFallback": "auto",
"retries": 42
}