otel's "no overflowing controls at 360px" was red in WebKit with no
change to the page, on origin/main's own copy of the test too (1 of 6
cases passed, 2 runs, at a load average near 11). #1659's injected runs
first showed it.
A probe at each width, run straight after setViewportSize and again two
frames later, showed the cause. Going from 1100px to 520px, innerWidth
is already 520 and body no longer has side-nav. But the views still
start at left 212, the side nav's padding at the old width. #otelList
measures 268px instead of 488px. Two frames later the views start at 0
and the list is 488px. At 360px a row then measured 106-108px instead
of 320px, so its control overflowed it.
The test now waits two requestAnimationFrames after each
setViewportSize before measuring. The page is unchanged: a user's
window is drawn at its new width by the next frame.
Run (WebKit, the engine that was red):
- Without the wait: 14 of 15 cases red over 5 runs, each on "no
overflowing controls at 360px".
- With it: 20 runs, 60 of 60 cases passed (load average 15-16).
33 other test files measure right after setViewportSize. They are filed
as a follow-up, not changed here.