推进 INI 面板 shell handoff summary browser API

This commit is contained in:
2026-06-15 08:12:33 +08:00
parent b31b9a2f8a
commit 01817f6493
9 changed files with 133 additions and 9 deletions

View File

@@ -73,6 +73,7 @@
!launchApi?.getShellIntegrationSchema ||
!launchApi?.getShellIntegrationManifest ||
!launchApi?.getShellIntegrationReadiness ||
!launchApi?.getShellSessionHandoffSummary ||
!launchApi?.getLauncherLinks ||
!launchApi?.getControlPageApiMethods
) {
@@ -112,12 +113,13 @@
);
assertEqual(
launchApiManifest.methods.join(","),
"isSupportedLaunchApiManifest,getLaunchApiSchema,getLaunchApiManifest,getShellIntegrationSchema,getShellIntegrationManifest,getShellIntegrationReadiness,getLauncherLinks,getControlPageApiMethods",
"isSupportedLaunchApiManifest,getLaunchApiSchema,getLaunchApiManifest,getShellIntegrationSchema,getShellIntegrationManifest,getShellIntegrationReadiness,getShellSessionHandoffSummary,getLauncherLinks,getControlPageApiMethods",
"launch API manifest methods",
);
const shellIntegrationSchema = launchApi.getShellIntegrationSchema();
const shellIntegrationManifest = launchApi.getShellIntegrationManifest();
const shellIntegrationReadiness = launchApi.getShellIntegrationReadiness();
const shellSessionHandoffSummary = launchApi.getShellSessionHandoffSummary();
assertEqual(
shellIntegrationSchema.manifestVersion,
1,
@@ -158,6 +160,26 @@
"",
"shell integration readiness missing checks",
);
assertEqual(
shellSessionHandoffSummary.ready,
true,
"shell session handoff summary readiness",
);
assertEqual(
shellSessionHandoffSummary.targetPage.href,
"./control-page.html",
"shell session handoff summary target",
);
assertEqual(
shellSessionHandoffSummary.readonlyStatusFields.includes("session"),
true,
"shell session handoff summary readonly fields",
);
assertEqual(
shellSessionHandoffSummary.persistenceCapabilities.length,
3,
"shell session handoff summary persistence capabilities",
);
assertEqual(
JSON.stringify(shellIntegrationManifest),
JSON.stringify(createIniPanelShellIntegrationManifest()),