/** * @file * * Integration-time runner that executes a suite once per **distinct** supported * Obsidian version. * * Thin glue over the pure `version-matrix.ts` decision layer: the only things * that happen here are the single manifest fetch and the logging. Everything * that decides — normalizing the requested specifiers, resolving them, * de-duplicating on the resolved version, sequencing the runs, and building the * failure summary — is pure and unit-tested next door. * * The loop lives above the transport rather than inside it because a test * framework's global setup cannot re-run its own test files: it launches one * instance for one run. Keeping the loop framework-agnostic (the caller supplies * `run`) is what lets Vitest, Jest, and manual consumers all inherit it (L6). */ import type { ObsidianVersionMatrixEntry } from './version-matrix.cjs'; /** * Parameters for {@link runObsidianVersionMatrix}. */ export interface RunObsidianVersionMatrixParams { /** * Runs the suites against one concrete Obsidian version, throwing on failure. * * The entry's `version` is the concrete `x.y.z` to pin — typically forwarded to * the test-runner child as `OBSIDIAN_VERSION`. */ readonly run: (entry: ObsidianVersionMatrixEntry) => Promise | void; /** * The version specifiers to run against: an array, or a comma-separated string * so an env var can be passed straight through. * * Each accepts an explicit `'x.y.z'`, `'public-latest'`, or `'catalyst-latest'`. * Defaults to both ends of the supported range when omitted or empty, and * the list is always de-duplicated on the **resolved** version — so when public * has caught up to catalyst, the suites run once. */ readonly versions?: readonly string[] | string | undefined; } /** * Runs a suite once per distinct supported Obsidian version. * * @param params - The per-version runner and the requested versions. * @returns A {@link Promise} that resolves once every version has run successfully. * @throws Error if no version could be resolved, or an {@link AggregateError} * naming every version whose run failed. */ export declare function runObsidianVersionMatrix(params: RunObsidianVersionMatrixParams): Promise;