@@ -46,12 +46,11 @@ def pytest_addoption(parser):
4646 --disable-csp (This disables the Content Security Policy of websites.)
4747 --enable-sync (The option to enable "Chrome Sync".)
4848 --use-auto-ext (The option to use Chrome's automation extension.)
49- --no-sandbox (The option to enable Chrome's "No-Sandbox" feature.)
50- --disable-gpu (The option to enable Chrome's "Disable GPU" feature.)
5149 --incognito (The option to enable Chrome's Incognito mode.)
5250 --guest (The option to enable Chrome's Guest mode.)
5351 --devtools (The option to open Chrome's DevTools when the browser opens.)
5452 --reuse-session (The option to reuse the browser session between tests.)
53+ --crumbs (Option to delete all cookies between tests reusing a session.)
5554 --maximize (The option to start with the web browser maximized.)
5655 --save-screenshot (The option to save a screenshot after each test.)
5756 --visual-baseline (Set the visual baseline for Visual/Layout tests.)
@@ -363,12 +362,14 @@ def pytest_addoption(parser):
363362 action = "store_true" ,
364363 dest = 'no_sandbox' ,
365364 default = False ,
366- help = """Using this enables the "No Sandbox" feature.""" )
365+ help = """Using this enables the "No Sandbox" feature.
366+ (This setting is now always enabled by default.)""" )
367367 parser .addoption ('--disable_gpu' , '--disable-gpu' ,
368368 action = "store_true" ,
369369 dest = 'disable_gpu' ,
370370 default = False ,
371- help = """Using this enables the "Disable GPU" feature.""" )
371+ help = """Using this enables the "Disable GPU" feature.
372+ (This setting is now always enabled by default.)""" )
372373 parser .addoption ('--incognito' , '--incognito_mode' , '--incognito-mode' ,
373374 action = "store_true" ,
374375 dest = 'incognito' ,
@@ -390,6 +391,13 @@ def pytest_addoption(parser):
390391 default = False ,
391392 help = """The option to reuse the selenium browser window
392393 session between tests.""" )
394+ parser .addoption ('--crumbs' ,
395+ action = "store_true" ,
396+ dest = 'crumbs' ,
397+ default = False ,
398+ help = """The option to delete all cookies between tests
399+ that reuse the same browser session. This option
400+ is only needed when using "--reuse-session".""" )
393401 parser .addoption ('--maximize_window' , '--maximize-window' , '--maximize' ,
394402 '--fullscreen' ,
395403 action = "store_true" ,
@@ -478,6 +486,7 @@ def pytest_configure(config):
478486 sb_config .guest_mode = config .getoption ('guest_mode' )
479487 sb_config .devtools = config .getoption ('devtools' )
480488 sb_config .reuse_session = config .getoption ('reuse_session' )
489+ sb_config .crumbs = config .getoption ('crumbs' )
481490 sb_config .shared_driver = None # The default driver for session reuse
482491 sb_config .maximize_option = config .getoption ('maximize_option' )
483492 sb_config .save_screenshot = config .getoption ('save_screenshot' )
0 commit comments