Problem
The main CI run for release-prep commit 84fc358 failed because test/bun-optimizations.test.ts compares two sub-millisecond wall-clock samples and requires memoization to beat a tiny arithmetic loop in every run.
The failing sample measured the optimized loop at 0.061621 ms and the memoized loop at 0.245548 ms. The implementation revision immediately before it passed the same full suite, and the release-note commit changed only CHANGELOG.md.
Failure: https://github.com/stacksjs/bun-router/actions/runs/35571199259
Expected
Performance tests should verify deterministic optimization behavior or use a statistically sound benchmark outside the correctness suite. A unit test should not fail based on scheduler and timer noise at this scale.
Scope
- inspect what the optimizer contract actually promises,
- replace the one-sample timing comparison with deterministic behavior coverage,
- keep real measurements in the benchmark harness,
- validate on exact Bun 1.4.2 and link the green main CI run.