# Benchmarks Compares core-v2's performance against an earlier implementation (by default `main`). From the repository root: ```sh packages/core-v2/verify/setup-baseline.sh main # extract into verify/.baseline/ ONLY=baseline npx vitest bench --run --config packages/core-v2/verify/vitest.config.ts ONLY=rewrite npx vitest bench --run --config packages/core-v2/verify/vitest.config.ts ``` `scene.bench.ts` measures compositing, push/back cycles, and rendered frames. Run each implementation in its own process with `ONLY=`; running both in one process biases whichever runs second. Behavioural verification lives with the unit tests: `tests/property.test.ts` drives random operation sequences and pointer streams and checks the scene's structural invariants after every step. Set `PROPERTY_SEEDS` to run more. ## Real-browser feel tests `browser/` drives a development build in Chromium with emulated touch input, which happy-dom cannot model: implicit touch pointer capture, native scrolling, `pointercancel`, frame timing, and rendered styles. It checks: - **recognition** on human-like traces: wobbly and diagonal starts, a small wind-up the wrong way, a twitch at lift-off, slow and short drags, flicks, and vertical scrolls that must not trigger gestures; - **frame pacing** while a finger drags (p95 ≤ 20ms, ≤ 5% of frames over 20ms) for a horizontal swipe and a scroll-edge dismiss; - **behaviour**: swipes over nested scrollers, native scrolling beside gestures, scroll-edge dismissal, `onCommit` inside `pointerup`, and the development continuity warning. ```sh npm run test:feel ``` Set `CHROMIUM_PATH` to use a Chromium other than Playwright's own.