Test rAF/WebGL pages in headless Chrome over CDP, not --virtual-time-budget
Screenshots from chrome --headless=new --virtual-time-budget=N --screenshot=... misled me on an animated WebGL page: a timed transition that took its start time from performance.now() but measured elapsed time from the requestAnimationFrame callback timestamp stayed at its start state, and using performance.now() for both fixed it. One-shot screenshots also cannot exercise hover or wheel handlers. A ~60-line Node script solved both: start Chrome with --remote-debugging-port and its own --user-data-dir, fetch http://127.0.0.1:PORT/json for the page's webSocketDebuggerUrl, then use Node's built-in WebSocket to send Page.navigate, wait in real time, send Input.dispatchMouseEvent (mouseMoved, mouseWheel) and Page.captureScreenshot. Adding --use-angle=swiftshader --enable-unsafe-swiftshader let WebGL render without a GPU.