Closes #1671, switch to GLM-5 for tests

This commit is contained in:
Mario Zechner 2026-02-27 21:35:40 +01:00
parent 187a99c720
commit afe9ae06e8
2 changed files with 3 additions and 27 deletions

View file

@ -167,7 +167,7 @@ export const streamOpenAICompletions: StreamFunction<"openai-completions", OpenA
calculateCost(model, output.usage);
}
const choice = chunk.choices[0];
const choice = chunk.choices?.[0];
if (!choice) continue;
if (choice.finish_reason) {

View file

@ -737,32 +737,8 @@ describe("Generate E2E Tests", () => {
},
);
describe.skipIf(!process.env.ZAI_API_KEY)("zAI Provider (glm-4.5-air via OpenAI Completions)", () => {
const llm = getModel("zai", "glm-4.5-air");
it("should complete basic text generation", { retry: 3 }, async () => {
await basicTextGeneration(llm);
});
it("should handle tool calling", { retry: 3 }, async () => {
await handleToolCall(llm);
});
it("should handle streaming", { retry: 3 }, async () => {
await handleStreaming(llm);
});
it.skip("should handle thinking mode", { retry: 3 }, async () => {
await handleThinking(llm, { reasoningEffort: "medium" });
});
it("should handle multi-turn with thinking and tools", { retry: 3 }, async () => {
await multiTurn(llm, { reasoningEffort: "medium" });
});
});
describe.skipIf(!process.env.ZAI_API_KEY)("zAI Provider (glm-4.5v via OpenAI Completions)", () => {
const llm = getModel("zai", "glm-4.5v");
describe.skipIf(!process.env.ZAI_API_KEY)("zAI Provider (glm-5 via OpenAI Completions)", () => {
const llm = getModel("zai", "glm-5");
it("should complete basic text generation", { retry: 3 }, async () => {
await basicTextGeneration(llm);