推进 INI 面板 shell handoff action plan
This commit is contained in:
@@ -80,6 +80,7 @@
|
||||
!launchApi?.getShellSessionHandoffDisplayViewModel ||
|
||||
!launchApi?.getShellSessionHandoffSnapshot ||
|
||||
!launchApi?.getShellSessionHandoffRenderState ||
|
||||
!launchApi?.getShellSessionHandoffActionPlan ||
|
||||
!launchApi?.getLauncherLinks ||
|
||||
!launchApi?.getControlPageApiMethods
|
||||
) {
|
||||
@@ -119,7 +120,7 @@
|
||||
);
|
||||
assertEqual(
|
||||
launchApiManifest.methods.join(","),
|
||||
"isSupportedLaunchApiManifest,getLaunchApiSchema,getLaunchApiManifest,getShellIntegrationSchema,getShellIntegrationManifest,getShellIntegrationReadiness,getShellSessionHandoffSummarySchema,getShellSessionHandoffSummary,isSupportedShellSessionHandoffSummary,getShellSessionHandoffCompatibilityReport,getShellSessionHandoffDisplayViewModel,getShellSessionHandoffSnapshot,getShellSessionHandoffRenderState,getLauncherLinks,getControlPageApiMethods",
|
||||
"isSupportedLaunchApiManifest,getLaunchApiSchema,getLaunchApiManifest,getShellIntegrationSchema,getShellIntegrationManifest,getShellIntegrationReadiness,getShellSessionHandoffSummarySchema,getShellSessionHandoffSummary,isSupportedShellSessionHandoffSummary,getShellSessionHandoffCompatibilityReport,getShellSessionHandoffDisplayViewModel,getShellSessionHandoffSnapshot,getShellSessionHandoffRenderState,getShellSessionHandoffActionPlan,getLauncherLinks,getControlPageApiMethods",
|
||||
"launch API manifest methods",
|
||||
);
|
||||
const shellIntegrationSchema = launchApi.getShellIntegrationSchema();
|
||||
@@ -131,6 +132,7 @@
|
||||
const shellSessionHandoffDisplayViewModel = launchApi.getShellSessionHandoffDisplayViewModel();
|
||||
const shellSessionHandoffSnapshot = launchApi.getShellSessionHandoffSnapshot();
|
||||
const shellSessionHandoffRenderState = launchApi.getShellSessionHandoffRenderState();
|
||||
const shellSessionHandoffActionPlan = launchApi.getShellSessionHandoffActionPlan();
|
||||
assertEqual(
|
||||
shellIntegrationSchema.manifestVersion,
|
||||
1,
|
||||
@@ -241,6 +243,26 @@
|
||||
"Ready: No blocking reasons",
|
||||
"shell session handoff render-state status",
|
||||
);
|
||||
assertEqual(
|
||||
shellSessionHandoffActionPlan.planVersion,
|
||||
1,
|
||||
"shell session handoff action-plan version",
|
||||
);
|
||||
assertEqual(
|
||||
shellSessionHandoffActionPlan.ready,
|
||||
true,
|
||||
"shell session handoff action-plan readiness",
|
||||
);
|
||||
assertEqual(
|
||||
shellSessionHandoffActionPlan.nextSteps.map(({ id }) => id).join(","),
|
||||
"open-control-page,read-readonly-status",
|
||||
"shell session handoff action-plan next steps",
|
||||
);
|
||||
assertEqual(
|
||||
shellSessionHandoffActionPlan.requiredMethods.readStatus,
|
||||
"readControlPageStatus",
|
||||
"shell session handoff action-plan read method",
|
||||
);
|
||||
assertEqual(
|
||||
JSON.stringify(shellSessionHandoffSnapshot.readiness),
|
||||
JSON.stringify(shellIntegrationReadiness),
|
||||
@@ -261,6 +283,11 @@
|
||||
JSON.stringify(shellSessionHandoffDisplayViewModel.rows),
|
||||
"shell session handoff render-state rows",
|
||||
);
|
||||
assertEqual(
|
||||
JSON.stringify(shellSessionHandoffActionPlan.displayRows),
|
||||
JSON.stringify(shellSessionHandoffRenderState.rows),
|
||||
"shell session handoff action-plan rows",
|
||||
);
|
||||
assertEqual(
|
||||
launchDoc.querySelector("[data-handoff-status]").textContent,
|
||||
"Ready: No blocking reasons",
|
||||
|
||||
@@ -70,7 +70,8 @@ TOOL_TABLE = browser-shell-tool.tbl
|
||||
!launchApi?.getShellSessionHandoffCompatibilityReport ||
|
||||
!launchApi?.getShellSessionHandoffDisplayViewModel ||
|
||||
!launchApi?.getShellSessionHandoffSnapshot ||
|
||||
!launchApi?.getShellSessionHandoffRenderState
|
||||
!launchApi?.getShellSessionHandoffRenderState ||
|
||||
!launchApi?.getShellSessionHandoffActionPlan
|
||||
) {
|
||||
throw new Error("launch API namespace did not expose shell integration helpers");
|
||||
}
|
||||
@@ -83,6 +84,7 @@ TOOL_TABLE = browser-shell-tool.tbl
|
||||
const handoffDisplay = launchApi.getShellSessionHandoffDisplayViewModel();
|
||||
const handoffSnapshot = launchApi.getShellSessionHandoffSnapshot();
|
||||
const handoffRenderState = launchApi.getShellSessionHandoffRenderState();
|
||||
const handoffActionPlan = launchApi.getShellSessionHandoffActionPlan();
|
||||
assertEqual(handoffSummarySchema.summaryVersion, 1, "shell handoff summary schema version");
|
||||
assertEqual(
|
||||
launchApi.isSupportedShellSessionHandoffSummary(handoffSummary),
|
||||
@@ -99,6 +101,13 @@ TOOL_TABLE = browser-shell-tool.tbl
|
||||
assertEqual(handoffRenderState.ready, true, "shell handoff render-state readiness");
|
||||
assertEqual(handoffRenderState.statusLine, "Ready: No blocking reasons", "shell handoff render-state status");
|
||||
assertEqual(handoffRenderState.rows.length, handoffDisplay.rows.length, "shell handoff render-state rows");
|
||||
assertEqual(handoffActionPlan.ready, true, "shell handoff action-plan readiness");
|
||||
assertEqual(handoffActionPlan.targetPage.href, "./control-page.html", "shell handoff action-plan target");
|
||||
assertEqual(
|
||||
handoffActionPlan.nextSteps.map(({ id }) => id).join(","),
|
||||
"open-control-page,read-readonly-status",
|
||||
"shell handoff action-plan next steps",
|
||||
);
|
||||
assertEqual(readiness.phase, "ready", "shell integration readiness phase");
|
||||
assertEqual(readiness.ready, true, "shell integration readiness");
|
||||
assertEqual(readiness.missing.join(","), "", "shell integration readiness missing checks");
|
||||
|
||||
Reference in New Issue
Block a user