Bug 1892091 Comment 0 Edit History

Note: The actual edited comment in the bug view page will always show the original commenter’s name and original timestamp.

Due to intermittent test failures I switched from `synthesizeMouse` to running `.click()` in the `<a>` element + a test helper for user activation. This isn't ideal since it doesn't behave the same way as a real user click would. `synthesizeMouseAtCenter` is a much better fit.

The intermittent test failures mostly appeared in `browser_bouncetracking_stateful_storage.js` and `browser_bouncetracking_stateful_cookies.js`. The click would not go through in some of the `--verify` runs. From debugging it looks like the `<a>` element isn't hit though it sometimes hits the document or the body element. :mconley suggested it might be Bug 1743857 where we race the `SpecialPowers.spawn` call and the click call. It's also possible that layout hasn't happened yet when we try to click. I did ensure that the page is fully loaded before injecting the element.

Code snippet from the intermittently failing test helper: https://gist.github.com/Trikolon/6576f76e2c642c4adcea4a43fedafdd6
Due to intermittent test failures I switched from `synthesizeMouse` to running `.click()` in the `<a>` element + a test helper for user activation. This isn't ideal since it doesn't behave the same way as a real user click would. `synthesizeMouseAtCenter` is a much better fit.

The intermittent test failures mostly appeared in `browser_bouncetracking_stateful_storage.js` and `browser_bouncetracking_stateful_cookies.js` on Windows and Linux. The click would not go through in some of the `--verify` runs. From debugging it looks like the `<a>` element isn't hit though it sometimes hits the document or the body element. :mconley suggested it might be Bug 1743857 where we race the `SpecialPowers.spawn` call and the click call. It's also possible that layout hasn't happened yet when we try to click. I did ensure that the page is fully loaded before injecting the element.

Code snippet from the intermittently failing test helper: https://gist.github.com/Trikolon/6576f76e2c642c4adcea4a43fedafdd6
Due to intermittent test failures I switched from `synthesizeMouse` to running `.click()` in the `<a>` element + a test helper for user activation. This isn't ideal since it doesn't behave the same way as a real user click would. `synthesizeMouseAtCenter` is a much better fit.

The intermittent test failures mostly appeared in `browser_bouncetracking_stateful_storage.js` and `browser_bouncetracking_stateful_cookies.js` on Windows and Linux. The click would not go through in some of the `--verify` runs. From debugging it looks like the `<a>` element isn't hit though it sometimes hits the document or the body element. :mconley suggested it might be Bug 1743857 where we race the `SpecialPowers.spawn` call and the click call. It's also possible that layout hasn't happened yet when we try to click. I did ensure that the page is fully loaded before injecting the element.

Code snippet from the intermittently failing test helper: https://gist.github.com/Trikolon/6576f76e2c642c4adcea4a43fedafdd6
Failure log: https://treeherder.mozilla.org/logviewer?job_id=454874029&repo=try&lineNumber=9370

Back to Bug 1892091 Comment 0