import { i as TestRunEvidence } from "./test-run-model-CF2EYJOQ.mjs"; import { MarquetteDiagnostic } from "./validate.mjs"; import { TestRunAdmissionDecision, TestRunCandidate } from "./test-run-admission.mjs"; //#region src/test-run-check.d.ts /** * Serialized `format` marker for retained tests-check records. * * Readers must reject any other value before trusting the record. */ declare const TEST_RUN_CHECK_FORMAT = "vize.test-run.check"; /** * Current serialized tests-check format. * * Readers must reject a higher value until they explicitly support it. */ declare const TEST_RUN_CHECK_FORMAT_VERSION = 1; /** * Retained, release-bound `tests` check for one deployment decision. * * The record replaces every generic test-result reference — a summary blob, * a report path, or a green workflow label — with the exact * `test-run:` admission id of an independently verified run, the six * candidate facts the run was admitted for, and the identity and instant of * the independent observer that recorded the admission. A release decision * retaining anything else as its tests evidence cannot pass * {@link verifyTestRunCheck}. */ interface TestRunCheck { /** Serialized format marker; always {@link TEST_RUN_CHECK_FORMAT}. */ readonly format: typeof TEST_RUN_CHECK_FORMAT; /** * Serialized format version. * * Defaults to {@link TEST_RUN_CHECK_FORMAT_VERSION}. */ readonly formatVersion?: typeof TEST_RUN_CHECK_FORMAT_VERSION; /** Exact `test-run:` admission id of the observed run. */ readonly evidence: string; /** Exact candidate facts the run was admitted for. */ readonly candidate: TestRunCandidate; /** * Identity of the independent observer that recorded the admission. * * The observer is the trusted promotion boundary, never the runner that * executed the tests. */ readonly observer: string; /** Millisecond-precision UTC instant the admission was observed. */ readonly observedAt: string; } /** * Validates a retained tests-check record structurally. * * Diagnostics use `check.` paths and are deterministic and sorted by path, * code, and message. A generic evidence reference fails here with * `VIZE_MARQUETTE_141`: only an exact `test-run:` admission id can * name retained test evidence. Structural validity never admits anything by * itself; {@link verifyTestRunCheck} must confirm the record against the * caller's candidate and the retained run. Codes, paths, messages, and * ordering are identical to the native implementation. */ declare function validateTestRunCheck(check: TestRunCheck): MarquetteDiagnostic[]; /** * Verifies one retained tests check against the caller's own facts. * * The caller supplies the candidate it is deciding from its own trusted * facts; the retained check must validate structurally, bind that candidate * exactly, name an observer independent from the run's runner, and be * observed no earlier than the run's completed verification. The referenced * record is then admitted exactly like {@link admitTestRun}: canonical * fingerprint, candidate bindings, expiry at `now`, verification outcome, * and skipped-test accounting all fail closed. Diagnostics, denial codes, * and ordering are identical to the native implementation, as pinned by the * shared check-decision fixtures. */ declare function verifyTestRunCheck(check: TestRunCheck, candidate: TestRunCandidate, evidence: TestRunEvidence, now: string): Promise; //#endregion export { TEST_RUN_CHECK_FORMAT, TEST_RUN_CHECK_FORMAT_VERSION, TestRunCheck, validateTestRunCheck, verifyTestRunCheck }; //# sourceMappingURL=test-run-check.d.mts.map