Skip to content

Commit 8157092

Browse files
jdonelsonclaude
andcommitted
console: Make the freshness "Now" test able to fail
Co-Authored-By: Claude Opus 5.5 <[email protected]>
1 parent e834f9e commit 8157092

1 file changed

Lines changed: 2 additions & 5 deletions

File tree

‎console/src/platform/freshness/freshnessRows.test.ts‎

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -163,12 +163,9 @@ describe("computeStats", () => {
163163
it('takes "Now" from the latest reading, not the worst in the last bin', () => {
164164
// At a wide range the final bin is a maximum over many minutes, so it
165165
// reads high for an object that has already recovered.
166-
const lastBinMax = Math.max(
167-
...(SERIES.spiky as number[]).map((r) => r as number),
168-
);
169-
expect(lastBinMax).toBe(9_000);
166+
const recovered = buildData({ recovered: [400, 410, 9_000] }, 3);
170167

171-
const stats = computeStats("spiky", data, 430);
168+
const stats = computeStats("recovered", recovered, 430);
172169
expect(stats.current).toBe(430);
173170
expect(stats.peak).toBe(9_000);
174171
});

0 commit comments

Comments
 (0)