test(FN-4620): complete Step 6 — wire board tools assertions

Fusion-Task-Id: FN-4620
Fusion-Task-Lineage: d3d05e54-e137-46ee-bb5d-d71aa03e5a48
This commit is contained in:
Fusion
2026-05-15 11:40:33 -07:00
committed by gsxdsm
parent 808103b5ad
commit dd6cf58505
4 changed files with 138 additions and 67 deletions

View File

@@ -1366,6 +1366,7 @@ async function ensureSessionAgent(
rootDir: string | undefined,
historyForReplay: Array<{ question: PlanningQuestion; response: unknown }>,
promptOverrides?: PromptOverrideMap,
store?: TaskStore,
): Promise<void> {
if (session.agent) {
return;
@@ -1377,7 +1378,13 @@ async function ensureSessionAgent(
);
}
session.agent = await createPlanningAgent(session, rootDir, undefined, undefined, promptOverrides);
if (!store) {
throw new InvalidSessionStateError(
"Planning session has no task store and cannot be resumed without project context",
);
}
session.agent = await createPlanningAgent(session, rootDir, store, undefined, undefined, promptOverrides);
if (historyForReplay.length === 0) {
return;