mirror of
https://github.com/garrytan/gstack.git
synced 2026-08-31 18:30:39 +02:00
carve-section-loading, codex-e2e-plan-format, codex-e2e-recommendation-substance, and llm-judge-recommendation gated on EVALS/tier (free suite loads them as describe.skip) but their names fell outside PAID_TEST_GLOBS, so no paid lane ever selected them — net execution zero, forever. The existing matrix tripwire filtered on isPaidTestFile() first, so it was blind to exactly this class (the same bug that hid the pre-split monolith's gate tests for ~8 releases). - PAID_TEST_GLOBS: codex-e2e* + skill-llm-eval* wildcards (replacing exact names) + llm-judge-recommendation + carve-section-loading; package.json's six test-script glob lists mirrored - codex-e2e-plan-format gains the explicit periodic tier gate its siblings carry (external-service rule) — without it the sharded runner's no-guard default would spawn Codex in the gate tier per PR - eval:bg:periodic --timeout 32400→37800: the census growth pushed the periodic worst case to 35910s; the old value had 270s of headroom BEFORE this change and would now kill healthy runs mid-flight - new test/paid-orphan-tripwire.test.ts: any EVALS/tier-gated test file outside the globs fails the free suite (reasoned SCANNER_EXEMPT for the gate helpers + meta-tests) — the class-killer - paid-shards pins updated: the four orphans now assert INSIDE the census Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
35 lines
1.6 KiB
TypeScript
35 lines
1.6 KiB
TypeScript
/**
|
|
* The ONE definition of which test files are paid (API spend, external
|
|
* services, e2e harnesses). package.json's test:gate/test:evals globs, the
|
|
* free-suite exclusion in scripts/test-free-shards.ts, and the sharded paid
|
|
* runner in scripts/test-paid-shards.ts all derive from this list — a file
|
|
* added to one and not the others either burns money in the free suite or
|
|
* silently never runs in the paid tier.
|
|
*/
|
|
|
|
import { matchGlob } from './touchfiles';
|
|
|
|
/** The exact globs package.json's `test:gate` passes to `bun test`. */
|
|
export const PAID_TEST_GLOBS = [
|
|
// skill-llm-eval* (not just the base file): skill-llm-eval-spec.test.ts
|
|
// fell outside the exact glob and could never run in any lane.
|
|
'test/skill-llm-eval*.test.ts',
|
|
'test/skill-e2e-*.test.ts',
|
|
'test/skill-routing-e2e.test.ts',
|
|
// codex-e2e* (was two exact names): codex-e2e-plan-format.test.ts and
|
|
// codex-e2e-recommendation-substance.test.ts were API-spending orphans —
|
|
// outside these globs they self-skipped in the free suite AND never
|
|
// entered the paid census. The same bug class as the deleted pre-split
|
|
// monolith (see test/paid-shards.test.ts's regression pin).
|
|
'test/codex-e2e*.test.ts',
|
|
'test/gemini-e2e.test.ts',
|
|
'test/llm-judge-recommendation.test.ts',
|
|
'test/carve-section-loading.test.ts',
|
|
] as const;
|
|
|
|
/** True when a repo-relative path (either slash style) is a paid test file. */
|
|
export function isPaidTestFile(relativePath: string): boolean {
|
|
const normalized = relativePath.replace(/\\/g, '/');
|
|
return PAID_TEST_GLOBS.some((glob) => matchGlob(normalized, glob));
|
|
}
|