test: add Novita provider tool support tests
Add comprehensive test coverage for Novita provider including exact match models, prefix match models, and unsupported model cases.
This commit is contained in:
parent
9fb3c93b9d
commit
6e91e3845c
1 changed files with 29 additions and 0 deletions
|
|
@ -280,6 +280,34 @@ describe("PROVIDER_TOOL_SUPPORT", () => {
|
|||
});
|
||||
});
|
||||
|
||||
describe("novita", () => {
|
||||
const supportsFn = PROVIDER_TOOL_SUPPORT["novita"];
|
||||
|
||||
it("should return true for exact match models", () => {
|
||||
expect(supportsFn("deepseek/deepseek-r1-0528")).toBe(true);
|
||||
expect(supportsFn("deepseek/deepseek-r1-turbo")).toBe(true);
|
||||
expect(supportsFn("deepseek/deepseek-v3-0324")).toBe(true);
|
||||
expect(supportsFn("deepseek/deepseek-v3-turbo")).toBe(true);
|
||||
expect(supportsFn("meta-llama/llama-3.3-70b-instruct")).toBe(true);
|
||||
expect(supportsFn("qwen/qwen-2.5-72b-instruct")).toBe(true);
|
||||
expect(supportsFn("zai-org/glm-4.5")).toBe(true);
|
||||
expect(supportsFn("moonshotai/kimi-k2-instruct")).toBe(true);
|
||||
});
|
||||
|
||||
it("should return true for prefix match models", () => {
|
||||
expect(supportsFn("qwen/qwen3-235b-a22b-instruct-2507")).toBe(true);
|
||||
expect(supportsFn("openai/gpt-oss-20b")).toBe(true);
|
||||
expect(supportsFn("openai/gpt-oss-120b")).toBe(true);
|
||||
});
|
||||
|
||||
it("should return false for unsupported models", () => {
|
||||
expect(supportsFn("deepseek/deepseek-chat")).toBe(false);
|
||||
expect(supportsFn("meta-llama/llama-2-7b")).toBe(false);
|
||||
expect(supportsFn("qwen/qwen-2.0-7b")).toBe(false);
|
||||
expect(supportsFn("openai/gpt-4")).toBe(false);
|
||||
});
|
||||
});
|
||||
|
||||
describe("edge cases", () => {
|
||||
it("should handle empty model names", () => {
|
||||
expect(PROVIDER_TOOL_SUPPORT["continue-proxy"]("")).toBe(false);
|
||||
|
|
@ -288,6 +316,7 @@ describe("PROVIDER_TOOL_SUPPORT", () => {
|
|||
expect(PROVIDER_TOOL_SUPPORT["gemini"]("")).toBe(false);
|
||||
expect(PROVIDER_TOOL_SUPPORT["bedrock"]("")).toBe(false);
|
||||
expect(PROVIDER_TOOL_SUPPORT["ollama"]("")).toBe(false);
|
||||
expect(PROVIDER_TOOL_SUPPORT["novita"]("")).toBe(false);
|
||||
});
|
||||
|
||||
it("should handle non-existent provider", () => {
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue