推进 INI 面板 shell integration manifest
This commit is contained in:
@@ -11,6 +11,7 @@
|
||||
createControlPageBrowserApiMethods,
|
||||
createIniPanelLaunchApiManifest,
|
||||
createIniPanelLauncherLinkViewModel,
|
||||
createIniPanelShellIntegrationManifest,
|
||||
createIniPanelShellViewModel,
|
||||
getIniPanelEntryByHref,
|
||||
getVisibleIniPanelEntries,
|
||||
@@ -69,6 +70,8 @@
|
||||
!launchApi?.isSupportedLaunchApiManifest ||
|
||||
!launchApi?.getLaunchApiSchema ||
|
||||
!launchApi?.getLaunchApiManifest ||
|
||||
!launchApi?.getShellIntegrationSchema ||
|
||||
!launchApi?.getShellIntegrationManifest ||
|
||||
!launchApi?.getLauncherLinks ||
|
||||
!launchApi?.getControlPageApiMethods
|
||||
) {
|
||||
@@ -108,9 +111,41 @@
|
||||
);
|
||||
assertEqual(
|
||||
launchApiManifest.methods.join(","),
|
||||
"isSupportedLaunchApiManifest,getLaunchApiSchema,getLaunchApiManifest,getLauncherLinks,getControlPageApiMethods",
|
||||
"isSupportedLaunchApiManifest,getLaunchApiSchema,getLaunchApiManifest,getShellIntegrationSchema,getShellIntegrationManifest,getLauncherLinks,getControlPageApiMethods",
|
||||
"launch API manifest methods",
|
||||
);
|
||||
const shellIntegrationSchema = launchApi.getShellIntegrationSchema();
|
||||
const shellIntegrationManifest = launchApi.getShellIntegrationManifest();
|
||||
assertEqual(
|
||||
shellIntegrationSchema.manifestVersion,
|
||||
1,
|
||||
"shell integration schema manifest version",
|
||||
);
|
||||
assertEqual(
|
||||
shellIntegrationManifest.apiName,
|
||||
"ini-panel-shell-integration",
|
||||
"shell integration manifest API name",
|
||||
);
|
||||
assertEqual(
|
||||
shellIntegrationManifest.compatibility.launchApiManifest,
|
||||
true,
|
||||
"shell integration launch compatibility",
|
||||
);
|
||||
assertEqual(
|
||||
shellIntegrationManifest.compatibility.controlPageApiManifest,
|
||||
true,
|
||||
"shell integration control-page compatibility",
|
||||
);
|
||||
assertEqual(
|
||||
shellIntegrationManifest.controlPageApiManifest.apiName,
|
||||
"ini-panel-control-page",
|
||||
"shell integration control-page manifest name",
|
||||
);
|
||||
assertEqual(
|
||||
JSON.stringify(shellIntegrationManifest),
|
||||
JSON.stringify(createIniPanelShellIntegrationManifest()),
|
||||
"shell integration manifest",
|
||||
);
|
||||
assertEqual(
|
||||
launchApiManifest.visibleEntries.length,
|
||||
2,
|
||||
|
||||
Reference in New Issue
Block a user