import { cleanup, fireEvent, render, screen } from "@testing-library/react"; import { afterEach, beforeEach, describe, expect, it, vi } from "vitest"; const runtimeMocks = vi.hoisted(() => ({ queue: { snapshot: null, loading: true, loadFailed: false, saveFailed: false, invalidReason: undefined as string | undefined, isDirty: false, }, session: { snapshot: null, loading: true, loadFailed: false, saveFailed: false, invalidReason: undefined as string | undefined, isDirty: false, }, })); vi.mock("react-i18next", () => ({ useTranslation: () => ({ t: (key: string) => key }), })); vi.mock("./agent-generated-task-title-settings", () => ({ AgentGeneratedTaskTitleSettings: () => null, })); vi.mock("./anchored-prompt-bar-settings", () => ({ AnchoredPromptBarSettings: () => null })); vi.mock("./archive-confirmation-settings", () => ({ ArchiveConfirmationSettings: () => null })); vi.mock("./creation-auto-focus-settings", () => ({ CreationAutoFocusSettings: () => null })); vi.mock("./mcp-task-agent-profile-default-settings", () => ({ MCPTaskAgentProfileDefaultSettings: () => null, })); vi.mock("./prevent-auto-start-agent-settings", () => ({ PreventAutoStartAgentSettings: () => null, })); vi.mock("./sleep-inhibition-settings", () => ({ SleepInhibitionSettings: ({ onAttentionChange, }: { onAttentionChange?: (needsAttention: boolean) => void; }) => (