test(studio): account for LM Studio provider

This commit is contained in:
Ma
2026-07-29 22:11:06 +08:00
parent 66fad52bc4
commit d08bbed005
+2 -2
View File
@@ -1062,12 +1062,12 @@ describe("createStudioServer daemon lifecycle", () => {
expect(res.status).toBe(200);
const body = await res.json() as { services: Array<{ service: string; group?: string; connected: boolean }> };
const bank = body.services.filter((s) => !s.service.startsWith("custom"));
expect(bank.length).toBe(37);
expect(bank.length).toBe(38);
expect(bank.every((s) => typeof s.group === "string")).toBe(true);
expect(bank.filter((s) => s.group === "overseas")).toHaveLength(5);
expect(bank.filter((s) => s.group === "china")).toHaveLength(18);
expect(bank.filter((s) => s.group === "aggregator")).toHaveLength(4);
expect(bank.filter((s) => s.group === "local")).toHaveLength(2);
expect(bank.filter((s) => s.group === "local")).toHaveLength(3);
expect(bank.filter((s) => s.group === "codingPlan")).toHaveLength(8);
expect(bank.filter((s) => s.group === "aggregator").map((s) => s.service)[0]).toBe("kkaiapi");
expect(body.services.find((s) => s.service === "moonshot")?.connected).toBe(true);