playwright: [Question] `context.waitForEvent('page')` not working on Github Actions
I have Playwright tests that perform an action that opens a new tab, and then assert on the properties of the new tab.
The test waits for context.waitForEvent('page'), and is getting a timeout on Github Actions.
The code is the head of this repo: https://github.com/canopy-js/canopy-js
The tests that are failing are eg https://github.com/canopy-js/canopy-js/blob/main/playwright/navigation.spec.js#L62
Here is an example of a failing build: https://github.com/canopy-js/canopy-js/actions/runs/2835914632
However, when I run these same tests locally (npx playwright test), there are no errors.
Any ideas what might be happening?
Thanks
About this issue
- Original URL
- State: closed
- Created 2 years ago
- Comments: 17 (6 by maintainers)
Hey guys. I stumbled upon this thread trying to solve the same issue. The thread didn’t solve it for me, but it pointed me in the right direction. Here is my solution to the problem. Now my tests run fine in mac and CI (linux).