refactor(tools): return complete analysis results inline

This commit is contained in:
morluto
2026-09-29 14:53:50 +08:00
parent c34efca4cd
commit 2a6eb41147
156 changed files with 2529 additions and 1891 deletions
+23
View File
@@ -75,6 +75,29 @@ describe("reconstruction coverage closure", () => {
});
});
it("returns recommendations for every missing required surface", () => {
const workspace = completeReconstructionCoverageData();
const boundary = workspace.boundaries[0];
if (boundary === undefined) throw new Error("Expected fixture boundary");
const missingSurfaces = Array.from(
{ length: 10_001 },
(_, index) => `missing.surface.${index}`,
);
const incomplete = createReconstructionCoverageData({
...workspace,
boundaries: [{ ...boundary, required_surface_ids: missingSurfaces }],
});
const result = evaluateReconstructionClosure(
incomplete,
boundary.boundary_id,
RECONSTRUCTION_COVERAGE_NOW,
);
expect(result.reasons).toHaveLength(missingSurfaces.length);
expect(result.recommended_probes).toHaveLength(missingSurfaces.length);
});
it("invalidates stale verifier contracts and detected authority routing", () => {
const workspace = completeReconstructionCoverageData();
const owner = workspace.owners[0];