Files
oh-my-pi/packages/ai/test/gitlab-duo-model-mapping.test.ts
T
can1357 3bbced9b83 feat: added canonical model ID support to GitLab Duo with fallback
- Enhanced GitLab Duo model mapping to support canonical model IDs with fallback lookup.
- Simplified Anthropic auth resolution from 4-tier to 3-tier priority system.
- Fixed artifact manager cache invalidation by validating session file before reuse.
- Improved JSONL parsing in stats package with streaming parser and error handling.
2026-02-22 11:23:32 +01:00

21 lines
653 B
TypeScript

import { describe, expect, test } from "bun:test";
import { getModelMapping } from "../src/providers/gitlab-duo";
describe("gitlab duo model mapping", () => {
test("resolves Duo alias IDs", () => {
const mapping = getModelMapping("duo-chat-gpt-5-codex");
expect(mapping).toBeDefined();
expect(mapping?.model).toBe("gpt-5-codex");
});
test("resolves canonical model IDs", () => {
const mapping = getModelMapping("gpt-5-codex");
expect(mapping).toBeDefined();
expect(mapping?.model).toBe("gpt-5-codex");
});
test("returns undefined for unknown IDs", () => {
expect(getModelMapping("totally-unknown-model")).toBeUndefined();
});
});