feat(FN-3400): add native shell connection handoff, plugin management CLI/l
This merge adds a complete plugin management system (FN-3565) with CLI commands, a loader, runner, and dashboard routes, along with project-scoped auth storage (FN-3544), native shell connection support for mobile (FN-3400) spanning onboarding, connection manager, and remote desktop handoff, and ref Fusion-Task-Id: FN-3400
This commit is contained in:
@@ -53,6 +53,21 @@ describe("MobileNativeShellBridge", () => {
|
||||
unsubscribe();
|
||||
});
|
||||
|
||||
it("dispatches shell open manager event", async () => {
|
||||
const { MobileNativeShellBridge } = await import("../plugins/native-shell.js");
|
||||
const bridge = new MobileNativeShellBridge(scanner as never);
|
||||
const listener = vi.fn();
|
||||
const originalWindow = (globalThis as { window?: Window }).window;
|
||||
const mockWindow = new EventTarget() as Window;
|
||||
(globalThis as { window?: Window }).window = mockWindow;
|
||||
mockWindow.addEventListener("shell:open-connection-manager", listener as EventListener);
|
||||
|
||||
await bridge.openConnectionManager();
|
||||
|
||||
expect(listener).toHaveBeenCalledTimes(1);
|
||||
(globalThis as { window?: Window }).window = originalWindow;
|
||||
});
|
||||
|
||||
it("rejects desktop mode switch", async () => {
|
||||
const { MobileNativeShellBridge } = await import("../plugins/native-shell.js");
|
||||
const bridge = new MobileNativeShellBridge(scanner as never);
|
||||
|
||||
Reference in New Issue
Block a user