

























@@ -2562,7 +2562,7 @@ describe("google-meet plugin", () => {
25622562expect(focusCall[3]).toEqual({ progress: false });
25632563});
256425642565-it("does not mutate realtime browser prompts when status is requested", async () => {
2565+it("refreshes blocked realtime browser health read-only when status is requested", async () => {
25662566let openedTab = false;
25672567const { methods, nodesInvoke } = setup(
25682568{
@@ -2574,7 +2574,22 @@ describe("google-meet plugin", () => {
25742574const raw = params as { path?: string; body?: { url?: string; targetId?: string } };
25752575if (command === "browser.proxy") {
25762576if (raw.path === "/tabs") {
2577-return { payload: { result: { running: true, tabs: [] } } };
2577+return {
2578+payload: {
2579+result: {
2580+running: true,
2581+tabs: openedTab
2582+ ? [
2583+{
2584+targetId: "tab-1",
2585+title: "Meet",
2586+url: "https://meet.google.com/abc-defg-hij",
2587+},
2588+]
2589+ : [],
2590+},
2591+},
2592+};
25782593}
25792594if (raw.path === "/tabs/open") {
25802595openedTab = true;
@@ -2621,18 +2636,31 @@ describe("google-meet plugin", () => {
26212636const join = (await invokeGoogleMeetGatewayMethodForTest(methods, "googlemeet.join", {
26222637url: "https://meet.google.com/abc-defg-hij",
26232638})) as { session: { id: string } };
2639+openedTab = true;
26242640nodesInvoke.mockClear();
2625264126262642const status = (await invokeGoogleMeetGatewayMethodForTest(methods, "googlemeet.status", {
26272643sessionId: join.session.id,
26282644})) as { session?: { chrome?: { health?: { manualActionRequired?: boolean } } } };
2629264526302646expect(status.session?.chrome?.health?.manualActionRequired).toBe(true);
2631-expect(
2632-nodesInvoke.mock.calls.some(
2633-([params]) => requireRecord(params, "node invoke").command === "browser.proxy",
2634-),
2635-).toBe(false);
2647+expect(nodesInvoke).toHaveBeenCalledWith(
2648+expect.objectContaining({
2649+command: "browser.proxy",
2650+params: expect.objectContaining({
2651+path: "/act",
2652+body: expect.objectContaining({ targetId: "tab-1" }),
2653+}),
2654+}),
2655+);
2656+expect(nodesInvoke).not.toHaveBeenCalledWith(
2657+expect.objectContaining({
2658+command: "browser.proxy",
2659+params: expect.objectContaining({
2660+path: "/permissions/grant",
2661+}),
2662+}),
2663+);
26362664});
2637266526382666it("retries caption enable until the captions button is available", async () => {
@@ -3573,6 +3601,52 @@ describe("google-meet plugin", () => {
35733601expect(result.speechOutputTimedOut).toBe(false);
35743602});
357536033604+it("uses the requested bidirectional realtime mode for test speech", async () => {
3605+const runtime = new GoogleMeetRuntime({
3606+config: resolveGoogleMeetConfig({ defaultMode: "agent" }),
3607+fullConfig: {} as never,
3608+runtime: {} as never,
3609+logger: noopLogger,
3610+});
3611+const session: GoogleMeetSession = {
3612+id: "meet_1",
3613+url: "https://meet.google.com/abc-defg-hij",
3614+transport: "chrome",
3615+mode: "bidi",
3616+state: "active",
3617+createdAt: "2026-04-27T00:00:00.000Z",
3618+updatedAt: "2026-04-27T00:00:00.000Z",
3619+participantIdentity: "signed-in Google Chrome profile",
3620+realtime: {
3621+enabled: true,
3622+strategy: "bidi",
3623+provider: "openai",
3624+toolPolicy: "safe-read-only",
3625+},
3626+chrome: {
3627+audioBackend: "blackhole-2ch",
3628+launched: true,
3629+health: { audioOutputActive: true, lastOutputBytes: 10 },
3630+},
3631+notes: [],
3632+};
3633+vi.spyOn(runtime, "list").mockReturnValue([]);
3634+const join = vi.spyOn(runtime, "join").mockResolvedValue({ session, spoken: true });
3635+3636+await runtime.testSpeech({
3637+url: "https://meet.google.com/abc-defg-hij",
3638+mode: "bidi",
3639+message: "Say exactly: hello.",
3640+});
3641+3642+expect(join).toHaveBeenCalledWith(
3643+expect.objectContaining({
3644+message: "Say exactly: hello.",
3645+mode: "bidi",
3646+}),
3647+);
3648+});
3649+35763650it("rejects observe-only mode for test speech", async () => {
35773651const runtime = new GoogleMeetRuntime({
35783652config: resolveGoogleMeetConfig({}),
此内容由惯性聚合(RSS阅读器)自动聚合整理,仅供阅读参考。 原文来自 — 版权归原作者所有。