File tree Expand file tree Collapse file tree 1 file changed +6
-7
lines changed
Expand file tree Collapse file tree 1 file changed +6
-7
lines changed Original file line number Diff line number Diff line change 1515
1616exec_async = os .getenv ('EXEC_ASYNC' )
1717
18+ options = ChromeOptions ()
19+
20+ # Refer https://www.selenium.dev/blog/2023/headless-is-going-away/ for the new way
21+ # to trigger browser in headless mode
22+ options .add_argument ("--headless=new" )
23+
1824if exec_async == 'true' :
1925 # logs via pytest-xdist
2026 # https://github.com/pytest-dev/pytest-xdist/issues/354#issuecomment-430502446
2127 # sys.stdout = sys.stderr
22-
23- options = ChromeOptions ()
24-
25- # Refer https://www.selenium.dev/blog/2023/headless-is-going-away/ for the new way
26- # to trigger browser in headless mode
27- options .add_argument ("--headless=new" )
28-
2928 @pytest .fixture (scope = 'function' )
3029 async def driver ():
3130 driver = await asyncio .to_thread (webdriver .Chrome , options = options )
You can’t perform that action at this time.
0 commit comments