Remove legacy orchestration and MCP aliases; reroute recursive pipeline API

This commit is contained in:
2026-02-23 16:02:20 -05:00
parent 62e2491cde
commit 1363bceecc
15 changed files with 88 additions and 102 deletions

View File

@@ -43,40 +43,35 @@ test("maps shared headers to codex http_headers", () => {
});
});
test("normalizes header aliases into a single headers object", () => {
test("normalizes headers into a single headers object", () => {
const normalized = normalizeSharedMcpServer({
url: "http://localhost:3000/mcp",
http_headers: {
"X-Source": "legacy",
},
headers: {
Authorization: "Bearer token",
},
});
assert.deepEqual(normalized.headers, {
"X-Source": "legacy",
Authorization: "Bearer token",
});
assert.equal("http_headers" in normalized, false);
});
test("maps legacy http_headers alias for claude conversion", () => {
const claudeConfig = toClaudeServerConfig("legacy-http-headers", {
type: "http",
url: "http://localhost:3000/mcp",
http_headers: {
Authorization: "Bearer token",
},
});
assert.deepEqual(claudeConfig, {
type: "http",
url: "http://localhost:3000/mcp",
headers: {
Authorization: "Bearer token",
},
});
test("rejects legacy shared MCP header alias http_headers", () => {
assert.throws(
() =>
parseMcpConfig({
servers: {
legacy: {
type: "http",
url: "http://localhost:3000/mcp",
http_headers: {
Authorization: "Bearer token",
},
},
},
}),
/unrecognized key/i,
);
});
test("throws for claude http server without url", () => {