fix linting error

This commit is contained in:
Ruben Casas 2026-02-16 22:20:06 +00:00
commit 87bb2425a3

View file

@ -13,8 +13,7 @@ type ToolListEntry = {
_meta: Record<string, unknown>; _meta: Record<string, unknown>;
}; };
let latestAppsTabProps: type AppsTabProps = {
| {
tools: ToolListEntry[]; tools: ToolListEntry[];
prefilledToolCall?: { prefilledToolCall?: {
id: number; id: number;
@ -25,8 +24,7 @@ let latestAppsTabProps:
}; };
} | null; } | null;
onPrefilledToolCallConsumed?: (callId: number) => void; onPrefilledToolCallConsumed?: (callId: number) => void;
} };
| undefined;
// Mock auth dependencies first // Mock auth dependencies first
jest.mock("@modelcontextprotocol/sdk/client/auth.js", () => ({ jest.mock("@modelcontextprotocol/sdk/client/auth.js", () => ({
@ -164,8 +162,7 @@ jest.mock("../components/ToolsTab", () => ({
jest.mock("../components/AppsTab", () => ({ jest.mock("../components/AppsTab", () => ({
__esModule: true, __esModule: true,
default: (props: typeof latestAppsTabProps) => { default: (props: AppsTabProps) => {
latestAppsTabProps = props;
const prefilled = const prefilled =
props && "prefilledToolCall" in props ? props.prefilledToolCall : null; props && "prefilledToolCall" in props ? props.prefilledToolCall : null;
const tools = props && "tools" in props ? props.tools : []; const tools = props && "tools" in props ? props.tools : [];
@ -200,7 +197,6 @@ describe("App - Tools to Apps prefilled handoff", () => {
beforeEach(() => { beforeEach(() => {
jest.clearAllMocks(); jest.clearAllMocks();
latestAppsTabProps = undefined;
window.location.hash = "#tools"; window.location.hash = "#tools";
}); });