diff --git a/tests/runner-e2e/catalog-overview.test.ts b/tests/runner-e2e/catalog-overview.test.ts index d13b651f895..d7938836ded 100644 --- a/tests/runner-e2e/catalog-overview.test.ts +++ b/tests/runner-e2e/catalog-overview.test.ts @@ -62,9 +62,15 @@ describe("display-only catalog overview", () => { expect(doc.querySelector('[data-execution-scope]')!.textContent).toContain('25 cases measured outside main · 49 never run · 1'); expect(() => parseCatalogOverview({...data,rows:data.rows.map((r,i)=>i===218?{...r,executionRecord:'never-run'}:r)})).toThrow('Inconsistent recorded'); }); + it.each([[152,"below"],[196,"equal to"],[200,"above"]] as const)("compares a ceiling of %i accurately", (ceiling, comparison) => { + const data=fixture(); data.accounting.theoreticalMainCeiling=ceiling; + expect(new JSDOM(page(data)).window.document.querySelector('main')!.textContent).toContain(`${ceiling}/244, ${comparison} the 196-case target`); + }); it("filters and resets actual DOM rows without treating unused initials as failures", () => { const dom=new JSDOM(page(fixture()),{runScripts:'dangerously',pretendToBeVisual:true}); const doc=dom.window.document; + for (const selector of ['[data-nav-view="attention"]','.report-global-nav a[href$="?view=history"]','.report-breadcrumbs']) expect(dom.window.getComputedStyle(doc.querySelector(selector)!).display).toBe('none'); + expect(dom.window.getComputedStyle(doc.querySelector('[data-nav-view="overview"]')!).display).not.toBe('none'); const select=doc.querySelector('[data-catalog-outcome]')!;select.value='unmeasured';select.dispatchEvent(new dom.window.Event('input')); expect([...doc.querySelectorAll('[data-catalog-row]')].filter(r=>!r.hidden)).toHaveLength(75); const allowance=doc.querySelector('[data-catalog-allowance]')!;allowance.value='unknown';allowance.dispatchEvent(new dom.window.Event('input')); @@ -99,5 +105,7 @@ describe("display-only catalog overview", () => { expect(normal).toContain('aria-label="Campaign summary"'); expect(normal).not.toContain('data-catalog-overview>'); expect(normal).toContain('data-report-scope="campaign"'); + const window=new JSDOM(normal).window; + expect(window.getComputedStyle(window.document.querySelector('[data-nav-view="attention"]')!).display).not.toBe('none'); }); }); diff --git a/tests/runner-e2e/catalog-overview.ts b/tests/runner-e2e/catalog-overview.ts index b785839d82d..c2023ec5b06 100644 --- a/tests/runner-e2e/catalog-overview.ts +++ b/tests/runner-e2e/catalog-overview.ts @@ -78,6 +78,7 @@ export function renderCatalogOverview(value: unknown, descriptions: ReadonlyMap< const data = parseCatalogOverview(value); const count = (state: CatalogOverviewRow["mainOutcome"]) => data.rows.filter(row => row.mainOutcome === state).length; const features = [...new Set(data.rows.map(row => row.scenarioId.split(".")[0]!))].sort(); + const ceilingComparison = data.accounting.theoreticalMainCeiling < 196 ? "below" : data.accounting.theoreticalMainCeiling === 196 ? "equal to" : "above"; const examples = exampleIds.filter(id => data.rows.some(row => row.scenarioId === id && row.mainOutcome === "passed")); return `

Chat feature catalog · private preview

All 244 scenarios

Recorded outcomes, remaining allowances and source readiness, shown separately.

Snapshot ${html(data.asOf)}

@@ -86,7 +87,7 @@ export function renderCatalogOverview(value: unknown, descriptions: ReadonlyMap<

${data.rows.filter(row => row.executionRecord.startsWith("candidate-")).length} cases measured outside main · ${data.rows.filter(row => row.executionRecord === "never-run").length} never run · ${data.rows.filter(row => row.executionRecord === "unknown").length} with unknown execution evidence. A missing main measurement is not a claim that the case never ran. Candidate PASS and FAIL stay outside the main qualification total.

${examples.length ? `

Passing feature examples

` : ""} -
Attempt accounting and limits

${data.accounting.retainedRawResults} retained results · ${data.accounting.closedSlots} closed ordinal slots · ${data.accounting.exhaustedFinals} exhausted finals · ${data.rows.filter(row => row.allowance === "unknown").length} unknown allowance.

The theoretical eligible main ceiling is ${data.accounting.theoreticalMainCeiling}/244, below the 196-case target. This is an upper bound, not a forecast or an execution approval.

+
Attempt accounting and limits

${data.accounting.retainedRawResults} retained results · ${data.accounting.closedSlots} closed ordinal slots · ${data.accounting.exhaustedFinals} exhausted finals · ${data.rows.filter(row => row.allowance === "unknown").length} unknown allowance.

The theoretical eligible main ceiling is ${data.accounting.theoreticalMainCeiling}/244, ${ceilingComparison} the 196-case target. This is an upper bound, not a forecast or an execution approval.

244 scenarios

${[...data.rows].sort((a,b) => a.scenarioId.localeCompare(b.scenarioId)).map(row => ``).join("")}
ScenarioMain outcomeRecorded executionAllowanceSource readinessNext action
${html(label(row.scenarioId.split(".")[1]!))}${html(label(row.scenarioId.split(".")[0]!))}${html(row.scenarioId)}${descriptions.has(row.scenarioId) ? `
What this test asks

Human request: ${html(descriptions.get(row.scenarioId)!.query)}

Expected outcome: ${html(descriptions.get(row.scenarioId)!.expectedOutcome)}

` : ""}
${outcomes[row.mainOutcome]}${executionRecords[row.executionRecord]}${allowances[row.allowance]}${readiness[row.sourceReadiness]}${html(nextAction(row))}
Metadata overview only · No result cards or evidence files are synthesized
@@ -94,6 +95,9 @@ export function renderCatalogOverview(value: unknown, descriptions: ReadonlyMap< } export const catalogOverviewStyles = ` +body[data-catalog-metadata] .report-global-nav a[data-nav-view="attention"], +body[data-catalog-metadata] .report-global-nav a[href$="?view=history"], +body[data-catalog-metadata] .report-breadcrumbs { display:none; } .catalog-scope { border:1px solid var(--border); border-radius:var(--radius); background:var(--raised); padding:20px; margin:24px 0; } .catalog-scope p { margin-bottom:0; } .catalog-table { width:100%; border-collapse:collapse; text-align:left; } diff --git a/tests/runner-e2e/dashboard.ts b/tests/runner-e2e/dashboard.ts index 46fc6e570c4..7de3ce065fe 100644 --- a/tests/runner-e2e/dashboard.ts +++ b/tests/runner-e2e/dashboard.ts @@ -871,7 +871,7 @@ export function renderRunnerE2EDashboard(input: RunnerDashboardInput) { ${catalogOverviewStyles} - + ${renderReportShell(catalogOverview ? { history: input.history } : { campaignId: input.campaign?.campaignId, catalog, history: input.history })}
${catalogOverview ?? `