forked from NoeFabris/opencode-antigravity-auth
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmodels.test.ts
More file actions
57 lines (49 loc) · 1.77 KB
/
Copy pathmodels.test.ts
File metadata and controls
57 lines (49 loc) · 1.77 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
import { describe, expect, it } from "vitest";
import { OPENCODE_MODEL_DEFINITIONS } from "./models";
const getModel = (name: string) => {
const model = OPENCODE_MODEL_DEFINITIONS[name];
if (!model) {
throw new Error(`Missing model definition for ${name}`);
}
return model;
};
describe("OPENCODE_MODEL_DEFINITIONS", () => {
it("includes the full set of configured models", () => {
const modelNames = Object.keys(OPENCODE_MODEL_DEFINITIONS).sort();
expect(modelNames).toEqual([
"antigravity-claude-opus-4-6-thinking",
"antigravity-claude-sonnet-4-6",
"antigravity-gemini-3-flash",
"antigravity-gemini-3-pro",
"antigravity-gemini-3.1-pro",
"gemini-2.5-flash",
"gemini-2.5-pro",
"gemini-3-flash-preview",
"gemini-3-pro-preview",
"gemini-3.1-pro-preview",
"gemini-3.1-pro-preview-customtools",
]);
});
it("defines Gemini 3 variants for Antigravity models", () => {
expect(getModel("antigravity-gemini-3-pro").variants).toEqual({
low: { thinkingLevel: "low" },
high: { thinkingLevel: "high" },
});
expect(getModel("antigravity-gemini-3.1-pro").variants).toEqual({
low: { thinkingLevel: "low" },
high: { thinkingLevel: "high" },
});
expect(getModel("antigravity-gemini-3-flash").variants).toEqual({
minimal: { thinkingLevel: "minimal" },
low: { thinkingLevel: "low" },
medium: { thinkingLevel: "medium" },
high: { thinkingLevel: "high" },
});
});
it("defines thinking budget variants for Claude thinking models", () => {
expect(getModel("antigravity-claude-opus-4-6-thinking").variants).toEqual({
low: { thinkingConfig: { thinkingBudget: 8192 } },
max: { thinkingConfig: { thinkingBudget: 32768 } },
});
});
});