diff --git a/src/__tests__/live-recorder.test.ts b/src/__tests__/live-recorder.test.ts new file mode 100644 index 0000000..ea45d0f --- /dev/null +++ b/src/__tests__/live-recorder.test.ts @@ -0,0 +1,11 @@ +import { describe, expect, it } from "vitest"; +import { classify } from "../../scripts/live-fixture-recorder.js"; + +describe("live fixture recorder endpoint classification", () => { + it.each([ + "https://api3.qoder.sh/algo/api/v2/service/pro/sse/agent_chat_generation?FetchKeys=llm_model_result&AgentId=agent_common&Encode=1", + "https://gateway.qoder.com.cn/algo/api/v2/service/pro/sse/agent_chat_generation?FetchKeys=llm_model_result&AgentId=agent_common&Encode=1", + ])("classifies the live %s endpoint as chat", (url) => { + expect(classify(url)).toBe("chat"); + }); +});