You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
but the first case can be interrupt by the second one. and the second one can success, the first one always fails, and lost its mouse focus.
The text was updated successfully, but these errors were encountered:
heliping
changed the title
use async in pyppeteer test, opened several browsers, but only the last one can run, the others fail to location.
Using async in pyppeteer test, opened several browsers, but only the last one can run, the others fail to location.
Aug 4, 2021
@heliping Judging from #91 pyppeteer uses asyncio tasks for clean up purposes. The default event_loop fixture of pytest-asyncio creates a new loop for each of your test cases. Issue #91 shows that this can cause the cleanup to fail in some cases. You can try using a session scoped event_loop fixture and see if it solves your problem:
As @AIGeneratedUsername and @asvetlov already mentioned we need more information to help you out. Feel free to reopen this issue, If you can provide a reproducible example.
I use pytest asyncio function with pyppeteer to test the web UI.
the testcase like this:
but the first case can be interrupt by the second one. and the second one can success, the first one always fails, and lost its mouse focus.
The text was updated successfully, but these errors were encountered: