mirror of
https://github.com/ChatGPTNextWeb/ChatGPT-Next-Web.git
synced 2025-11-18 06:53:41 +08:00
fix: allow isVisionModel utility function read env var
This commit is contained in:
@@ -49,10 +49,11 @@ describe("isVisionModel", () => {
|
||||
});
|
||||
|
||||
test("should identify models from VISION_MODELS env var", () => {
|
||||
process.env.VISION_MODELS = "custom-vision-model,another-vision-model";
|
||||
process.env.VISION_MODELS = "custom-vision-model,another-vision-model,OpenGVLab/InternVL2-26B";
|
||||
|
||||
expect(isVisionModel("custom-vision-model")).toBe(true);
|
||||
expect(isVisionModel("another-vision-model")).toBe(true);
|
||||
expect(isVisionModel("OpenGVLab/InternVL2-26B")).toBe(true);
|
||||
expect(isVisionModel("unrelated-model")).toBe(false);
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user