From cab7c4a5212eb5bf2b233c835ac57b5764a4e0f3 Mon Sep 17 00:00:00 2001 From: morluto <76467478+morluto@users.noreply.github.com> Date: Thu, 16 Jul 2026 19:42:23 +0800 Subject: [PATCH] test(mcp): derive sessionless managed inventory --- tests/enhancedTools.test.ts | 5 ++++- tests/integration/serverIntegration.test.ts | 5 ++++- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/tests/enhancedTools.test.ts b/tests/enhancedTools.test.ts index 1b39645a68..58d9231645 100644 --- a/tests/enhancedTools.test.ts +++ b/tests/enhancedTools.test.ts @@ -10,6 +10,7 @@ import { TOOL_CONTRACTS, } from "../src/contracts/toolContracts.js"; import { enhancedInputSchemas } from "../src/contracts/enhancedInputs.js"; +import { MANAGED_WORKFLOW_TOOL_CONTRACTS } from "../src/contracts/managedWorkflowToolContracts.js"; import { AnalysisOutputError } from "../src/domain/errors.js"; import { jsonValueSchema, type JsonValue } from "../src/domain/jsonValue.js"; import { err } from "../src/domain/result.js"; @@ -198,7 +199,9 @@ describe("enhanced MCP tools", () => { const client = await connect(); const listed = await client.listTools(); expect(listed.tools).toHaveLength( - TOOL_CONTRACTS.length - SESSION_TOOL_CONTRACTS.length, + TOOL_CONTRACTS.length - + SESSION_TOOL_CONTRACTS.length - + MANAGED_WORKFLOW_TOOL_CONTRACTS.length, ); expect( listed.tools diff --git a/tests/integration/serverIntegration.test.ts b/tests/integration/serverIntegration.test.ts index 3c17e4ef4f..7d35a505a7 100644 --- a/tests/integration/serverIntegration.test.ts +++ b/tests/integration/serverIntegration.test.ts @@ -23,6 +23,7 @@ import { SESSION_TOOL_CONTRACTS, TOOL_CONTRACTS, } from "../../src/contracts/toolContracts.js"; +import { MANAGED_WORKFLOW_TOOL_CONTRACTS } from "../../src/contracts/managedWorkflowToolContracts.js"; const resources: Array<{ close(): Promise }> = []; @@ -453,7 +454,9 @@ describe("full MCP integration with multi-tool sequences", () => { }); const listed = await client.listTools(); expect(listed.tools).toHaveLength( - TOOL_CONTRACTS.length - SESSION_TOOL_CONTRACTS.length, + TOOL_CONTRACTS.length - + SESSION_TOOL_CONTRACTS.length - + MANAGED_WORKFLOW_TOOL_CONTRACTS.length, ); const names = listed.tools.map((t) => t.name); expect(names).toContain("binary_overview");