fix(mcp): remove arbitrary schema byte gate

This commit is contained in:
morluto
2026-07-16 20:09:14 +08:00
parent f7aa19154d
commit fd08025dcd
9 changed files with 26 additions and 654 deletions
+1 -1
View File
@@ -8,7 +8,7 @@ const analysis = {
execute: () => Promise.resolve(ok(null)),
};
describe("beta.3 server composition", () => {
describe("MCP server composition", () => {
it("constructs independent MCP server instances", () => {
expect(createServer(analysis)).not.toBe(createServer(analysis));
});
+13 -7
View File
@@ -170,11 +170,19 @@ describe("canonical product catalog", () => {
}
});
it("reports tool, setup-client, and schema fact drift", async () => {
it("reports tool-family, setup-client, and schema fact drift", async () => {
const catalog = await createProductCatalog(root);
const firstFamily = catalog.tools.families[0];
if (firstFamily === undefined) throw new TypeError("Missing tool family");
const drifted = {
...catalog,
tools: { ...catalog.tools, total: catalog.tools.total + 1 },
tools: {
...catalog.tools,
families: [
{ ...firstFamily, count: firstFamily.count + 1 },
...catalog.tools.families.slice(1),
],
},
setup_clients: [
...catalog.setup_clients,
{
@@ -191,11 +199,9 @@ describe("canonical product catalog", () => {
),
};
const issues = await documentationFactIssues(root, drifted);
expect(
issues.some((issue) =>
issue.includes(`${String(catalog.tools.total + 1)}-tool`),
),
).toBe(true);
expect(issues.some((issue) => issue.includes("tool family counts"))).toBe(
true,
);
expect(issues.some((issue) => issue.includes("Future Client"))).toBe(true);
expect(issues.some((issue) => issue.includes("Process Capture v5"))).toBe(
true,