Skip to content

Autonomous development for real products. Governed agents build from specs you approve, follow the rules you set, and nothing merges until another agent proves it. Your decisions, judgement and taste are the bar that work must clear. Declare your vision and let agents build it.

test(stats): pass negative window values unambiguously [R1,R2]

Corey Olsona5c6e2cd7fc4
diff --git a/test/stats-cli.test.js b/test/stats-cli.test.js
index 67216e37..bf0624f7 100644
--- a/test/stats-cli.test.js
+++ b/test/stats-cli.test.js
@@ -231,7 +231,7 @@ test('[R1,R2,A1] stats window exposes measured tails in text and JSON without re
const help = await run(root, ['stats', '--help']);
assert.match(help.stdout, /--window <duration>/u);
for (const duration of ['0h', '-1h', '6', 'forever', '999999999999999999999d']) {
- const bad = await run(root, ['stats', '--window', duration, '--json'], clock);
+ const bad = await run(root, ['stats', `--window=${duration}`, '--json'], clock);
assert.equal(bad.code, 1);
assert.equal(bad.data.error.code, 'USAGE');
assert.match(bad.data.error.next, /--window 6h/u);