c
SpecReporter
Human-readable reporter: tests nested under their QUnit module, with failures shown inline where they happen. The shape Node, Vitest and Mocha all default to — raw TAP is a poor local-dev experience.
-
onRunEnd(): voidcontext: ReporterContext,info: RunEndInfo
Prints the outcome counts and, when any test failed, the failure recap.
-
onRunStart(): voidcontext: ReporterContext,info: RunStartInfo
Resets per-run state and prints the run banner.
-
onTestEnd(): voidcontext: ReporterContext,details: TestDetails
Prints the module header when it changes, then this test's result line.
f
formatFailureBlock(failures: FailureInfo[]): string
Renders every failing assertion of one test: message, values, and source location.
Usage
import * as mod from "lib/reporters/spec.ts";