property ScriptResult.tests

The suite the file declared, or null when it was a plain script.

A file that registers QUnit tests is a suite whichever verb points at it, so run runs it as one — same page, same evaluation, same reporters as test. Reporting it as an empty script run would be reporting success for tests that never ran.

When this is non-null, ScriptResult.ok and ScriptResult.exitCode are the suite's verdict rather than globalThis.exitCode.

Type

RunResult | null

Usage

import { type ScriptResult } from "lib/api/run.ts";