refactor: centralize TEST_MODELS and DEFAULT_PRESETS in constants.js

- Move TEST_MODELS and DEFAULT_PRESETS to src/constants.js as single source of truth
- Update test-models.cjs helper to use dynamic import from constants
- Make getTestModels() and getModels() async functions
- Update all test files to await async model config loading
- Remove duplicate THINKING_MODELS and getThinkingModels() from test helper
- Make thinking tests more lenient for Gemini (doesn't always produce thinking blocks)

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
Badri Narayanan S
2026-01-13 19:20:57 +05:30
parent 1a06098ae4
commit 12d196f6a0
11 changed files with 96 additions and 92 deletions

View File

@@ -165,7 +165,7 @@ drwxr-xr-x 4 user staff 128 Dec 19 10:00 tests`
}
async function runTests() {
const models = getTestModels();
const models = await getTestModels();
let allPassed = true;
for (const { family, model } of models) {