How a Playwright test clicked a button real users could never reach
A developer shipped a blog editor inside a dashboard that accidentally rendered in a fixed, non-scrollable shell due to a missing exclusion condition, cutting off the bottom of the form for all users. The end-to-end test still passed because Playwright's click() method automatically scrolls elements into view via JavaScript, bypassing the overflow:hidden restriction that blocked mouse and keyboard input. This revealed a key misunderstanding: an element with overflow:hidden still has a live scrollTop property and can be scrolled programmatically, even though users cannot scroll it manually. The bug was fixed with a two-word code addition and an inline comment to warn future developers. The incident highlights how automated tests can silently succeed on interactions that are genuinely inaccessible to real users.
This is an AI-generated summary. ShortSingh links to the original source for the complete article.
Discussion (0)
Log in to join the discussion and vote.
Log in