GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — test(voice): make sure setup never opens the microphone · pingdotgg/t3code@94a285b

File tree

Expand file treeCollapse file tree
Open diff view settings
Filter options
  • apps/web/src/speech
    • useEnvironmentSpeechInput.browser.test.tsx
Expand file treeCollapse file tree
Open diff view settings
Collapse file

‎apps/web/src/speech/useEnvironmentSpeechInput.browser.test.tsx‎

Copy file name to clipboardExpand all lines: apps/web/src/speech/useEnvironmentSpeechInput.browser.test.tsx
+23Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -330,6 +330,29 @@ it("retries a failed transcription on the same chosen environment", async () =>
330330
expect(mocks.committed).toHaveBeenCalledExactlyOnceWith("second try", expect.anything());
331331
});
332332

333+
it.each([
334+
["missing-model", 0],
335+
["ready", 1],
336+
["cloud", null],
337+
] as const)("setup-only with %s never starts the microphone", async (target, wizardStep) => {
338+
setup({ destination: "env-a" });
339+
if (target === "cloud") {
340+
mocks.cloudVoiceCapable.add("env-a");
341+
chooseAudioDestination({
342+
kind: "cloud",
343+
environmentId: EnvironmentId.make("env-a"),
344+
provider: "openai",
345+
});
346+
} else {
347+
mocks.modelState = target;
348+
}
349+
await using _screen = await render(<Probe />);
350+
expect(mocks.voice.available).toBe(true);
351+
await act(() => mocks.voice.start({ setupOnly: true }));
352+
expect(mocks.microphoneRequests).toEqual([]);
353+
expect(mocks.voice.setup.open ? mocks.voice.setup.step : null).toBe(wizardStep);
354+
});
355+
333356
it("reopens setup after reconnecting during a download and ignores its stale completion", async () => {
334357
setup({ destination: "env-a" });
335358
mocks.modelState = "missing-model";

0 commit comments

Comments
0 (0)
You are visitor 01402792 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.