perf(test): remove obsolete gateway channel pin proof (#123643)

This commit is contained in:
Peter Steinberger
2026-08-14 05:23:27 -07:00
committed by GitHub
parent 7fcddedaaf
commit d8db21e7a3
2 changed files with 0 additions and 65 deletions
-1
View File
@@ -1105,7 +1105,6 @@ function resolveGatewayServerShardName(file: string): string {
if (
name.startsWith("server.control-ui-root") ||
name.startsWith("server.ios-client-id") ||
name.startsWith("server.minimal-channel-pin") ||
name.startsWith("server.tools-catalog")
) {
return "agentic-control-plane-runtime-ui-tools";
@@ -1,64 +0,0 @@
/**
* Minimal channel pinning regression tests.
*/
import { afterEach, expect, test } from "vitest";
import { getChannelPlugin } from "../channels/plugins/index.js";
import {
getActivePluginRegistry,
resetPluginRuntimeStateForTest,
setActivePluginRegistry,
} from "../plugins/runtime.js";
import { createOutboundTestPlugin } from "../test-utils/channel-plugins.js";
import { createRegistry } from "./server.e2e-registry-helpers.js";
import {
getGatewayTestPort,
installGatewayTestHooks,
startTestGatewayServer,
} from "./test-helpers.js";
installGatewayTestHooks({ scope: "suite" });
const whatsappOutbound = {
deliveryMode: "direct" as const,
sendText: async () => ({ channel: "whatsapp", messageId: "text-1" }),
sendMedia: async () => ({ channel: "whatsapp", messageId: "media-1" }),
};
const replacementPlugin = createOutboundTestPlugin({
id: "whatsapp",
outbound: whatsappOutbound,
label: "WhatsApp Replacement",
});
const replacementRegistry = createRegistry([
{
pluginId: "whatsapp",
source: "test-replacement",
plugin: replacementPlugin,
},
]);
afterEach(() => {
resetPluginRuntimeStateForTest();
});
test("minimal gateway tracks later channel registry updates", async () => {
const prevRegistry = getActivePluginRegistry();
const prevVitest = process.env.VITEST;
resetPluginRuntimeStateForTest();
process.env.VITEST = "1";
const port = await getGatewayTestPort();
const server = await startTestGatewayServer(port);
try {
expect(getChannelPlugin("whatsapp")).not.toBe(replacementPlugin);
setActivePluginRegistry(replacementRegistry);
expect(getChannelPlugin("whatsapp")).toBe(replacementPlugin);
} finally {
await server.close();
process.env.VITEST = prevVitest;
resetPluginRuntimeStateForTest();
if (prevRegistry) {
setActivePluginRegistry(prevRegistry);
}
}
});