Routing reference test runs on today's routing loop; perf bench reads exported saves

The reference test from #106 now patches the loop as it looks after #96
(business-first passes) and also covers prefer, prepend and protect
customers. It catches an exit index that ignores RouteScript preferences,
which the shortcut test in speed.test.js cannot see.

npm run perf -- --save accepts files from the in-game Export save, so
scripts/benchmark-performance.js and its README section are not needed.
The performance skill documents --save, both equivalence tests and how to
handle noisy runs.
This commit is contained in:
Frederic Jung 2026-10-26 08:40:20 +01:00
parent 2366bb9a8f
commit e5deb90968
No known key found for this signature in database
6 changed files with 22 additions and 63 deletions

View file

@ -160,19 +160,3 @@ Issues and pull requests are welcome. See [CONTRIBUTING.md](CONTRIBUTING.md).
## License
[MIT](LICENSE) © 2026 Frederic Jung
## Benchmark an exported save
To measure simulation updates, actions, the closed mobile Networks sheet and
opening Connections with your own save:
```bash
node scripts/benchmark-performance.js /path/to/save.json
git show origin/main:site/index.html > /tmp/tubes-baseline.html
node scripts/benchmark-performance.js /path/to/save.json /tmp/tubes-baseline.html
```
The optional baseline compares timings and asserts that the complete serialized
simulation output matches. Saves may be plain state or exports wrapped in `S`.
These are headless JavaScript/DOM timings, not phone interaction or browser
painting measurements. For the seeded network benchmark used by CI, use `npm run perf`.