seleniumbase 4.31.1__py3-none-any.whl → 4.31.3__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- seleniumbase/__version__.py +1 -1
- seleniumbase/behave/behave_sb.py +8 -1
- seleniumbase/core/browser_launcher.py +36 -6
- seleniumbase/fixtures/base_case.py +7 -0
- seleniumbase/plugins/driver_manager.py +10 -2
- seleniumbase/plugins/pytest_plugin.py +11 -0
- seleniumbase/plugins/sb_manager.py +11 -2
- seleniumbase/plugins/selenium_plugin.py +11 -0
- {seleniumbase-4.31.1.dist-info → seleniumbase-4.31.3.dist-info}/METADATA +3 -2
- {seleniumbase-4.31.1.dist-info → seleniumbase-4.31.3.dist-info}/RECORD +14 -14
- {seleniumbase-4.31.1.dist-info → seleniumbase-4.31.3.dist-info}/LICENSE +0 -0
- {seleniumbase-4.31.1.dist-info → seleniumbase-4.31.3.dist-info}/WHEEL +0 -0
- {seleniumbase-4.31.1.dist-info → seleniumbase-4.31.3.dist-info}/entry_points.txt +0 -0
- {seleniumbase-4.31.1.dist-info → seleniumbase-4.31.3.dist-info}/top_level.txt +0 -0
seleniumbase/__version__.py
CHANGED
@@ -1,2 +1,2 @@
|
|
1
1
|
# seleniumbase package
|
2
|
-
__version__ = "4.31.
|
2
|
+
__version__ = "4.31.3"
|
seleniumbase/behave/behave_sb.py
CHANGED
@@ -71,7 +71,8 @@ behave -D agent="User Agent String" -D demo
|
|
71
71
|
-D rec-behave (Same as Recorder Mode, but also generates behave-gherkin.)
|
72
72
|
-D rec-sleep (If the Recorder is enabled, also records self.sleep calls.)
|
73
73
|
-D rec-print (If the Recorder is enabled, prints output after tests end.)
|
74
|
-
-D disable-
|
74
|
+
-D disable-cookies (Disable Cookies on websites. Pages might break!)
|
75
|
+
-D disable-js (Disable JavaScript on websites. Pages might break!)
|
75
76
|
-D disable-csp (Disable the Content Security Policy of websites.)
|
76
77
|
-D disable-ws (Disable Web Security on Chromium-based browsers.)
|
77
78
|
-D enable-ws (Enable Web Security on Chromium-based browsers.)
|
@@ -180,6 +181,7 @@ def get_configured_sb(context):
|
|
180
181
|
sb.database_env = "test"
|
181
182
|
sb.log_path = constants.Logs.LATEST + os.sep
|
182
183
|
sb.archive_logs = False
|
184
|
+
sb.disable_cookies = False
|
183
185
|
sb.disable_js = False
|
184
186
|
sb.disable_csp = False
|
185
187
|
sb.disable_ws = False
|
@@ -535,6 +537,10 @@ def get_configured_sb(context):
|
|
535
537
|
if low_key in ["archive-logs", "archive_logs"]:
|
536
538
|
sb.archive_logs = True
|
537
539
|
continue
|
540
|
+
# Handle: -D disable-cookies / disable_cookies
|
541
|
+
if low_key in ["disable-cookies", "disable_cookies"]:
|
542
|
+
sb.disable_cookies = True
|
543
|
+
continue
|
538
544
|
# Handle: -D disable-js / disable_js
|
539
545
|
if low_key in ["disable-js", "disable_js"]:
|
540
546
|
sb.disable_js = True
|
@@ -1005,6 +1011,7 @@ def get_configured_sb(context):
|
|
1005
1011
|
sb_config.pdb_option = sb.pdb_option
|
1006
1012
|
sb_config.rec_behave = sb.rec_behave
|
1007
1013
|
sb_config.rec_print = sb.rec_print
|
1014
|
+
sb_config.disable_cookies = sb.disable_cookies
|
1008
1015
|
sb_config.disable_js = sb.disable_js
|
1009
1016
|
sb_config.disable_csp = sb.disable_csp
|
1010
1017
|
sb_config.record_sleep = sb.record_sleep
|
@@ -1544,6 +1544,7 @@ def _set_chrome_options(
|
|
1544
1544
|
multi_proxy,
|
1545
1545
|
user_agent,
|
1546
1546
|
recorder_ext,
|
1547
|
+
disable_cookies,
|
1547
1548
|
disable_js,
|
1548
1549
|
disable_csp,
|
1549
1550
|
enable_ws,
|
@@ -1621,6 +1622,8 @@ def _set_chrome_options(
|
|
1621
1622
|
prefs["intl.accept_languages"] = locale_code
|
1622
1623
|
if block_images:
|
1623
1624
|
prefs["profile.managed_default_content_settings.images"] = 2
|
1625
|
+
if disable_cookies:
|
1626
|
+
prefs["profile.default_content_setting_values.cookies"] = 2
|
1624
1627
|
if disable_js:
|
1625
1628
|
prefs["profile.managed_default_content_settings.javascript"] = 2
|
1626
1629
|
if do_not_track:
|
@@ -2016,10 +2019,12 @@ def _set_firefox_options(
|
|
2016
2019
|
proxy_bypass_list,
|
2017
2020
|
proxy_pac_url,
|
2018
2021
|
user_agent,
|
2022
|
+
disable_cookies,
|
2019
2023
|
disable_js,
|
2020
2024
|
disable_csp,
|
2021
2025
|
firefox_arg,
|
2022
2026
|
firefox_pref,
|
2027
|
+
external_pdf,
|
2023
2028
|
):
|
2024
2029
|
blank_p = "about:blank"
|
2025
2030
|
options = webdriver.FirefoxOptions()
|
@@ -2031,7 +2036,6 @@ def _set_firefox_options(
|
|
2031
2036
|
options.set_preference("browser.newtab.url", blank_p)
|
2032
2037
|
options.set_preference("trailhead.firstrun.branches", "nofirstrun-empty")
|
2033
2038
|
options.set_preference("browser.aboutwelcome.enabled", False)
|
2034
|
-
options.set_preference("pdfjs.disabled", True)
|
2035
2039
|
options.set_preference("app.update.auto", False)
|
2036
2040
|
options.set_preference("app.update.enabled", False)
|
2037
2041
|
options.set_preference("browser.formfill.enable", False)
|
@@ -2089,6 +2093,8 @@ def _set_firefox_options(
|
|
2089
2093
|
"security.mixed_content.block_active_content", False
|
2090
2094
|
)
|
2091
2095
|
options.set_preference("security.warn_submit_insecure", False)
|
2096
|
+
if disable_cookies:
|
2097
|
+
options.set_preference("network.cookie.cookieBehavior", 2)
|
2092
2098
|
if disable_js:
|
2093
2099
|
options.set_preference("javascript.enabled", False)
|
2094
2100
|
if settings.DISABLE_CSP_ON_FIREFOX or disable_csp:
|
@@ -2116,13 +2122,20 @@ def _set_firefox_options(
|
|
2116
2122
|
options.set_preference(
|
2117
2123
|
"browser.helperApps.neverAsk.saveToDisk",
|
2118
2124
|
(
|
2119
|
-
"application/pdf,
|
2120
|
-
"text/csv,
|
2121
|
-
"text/octet-stream,
|
2122
|
-
"application/"
|
2123
|
-
"
|
2125
|
+
"application/pdf,application/zip,application/octet-stream,"
|
2126
|
+
"text/csv,text/xml,application/xml,text/plain,application/json,"
|
2127
|
+
"text/octet-stream,application/x-gzip,application/x-tar,"
|
2128
|
+
"application/java-archive,text/x-java-source,java,"
|
2129
|
+
"application/javascript,video/jpeg,audio/x-aac,image/svg+xml,"
|
2130
|
+
"application/x-font-woff,application/x-7z-compressed,"
|
2131
|
+
"application/mp4,video/mp4,audio/mp4,video/x-msvideo,"
|
2132
|
+
"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet"
|
2124
2133
|
),
|
2125
2134
|
)
|
2135
|
+
if external_pdf:
|
2136
|
+
options.set_preference("pdfjs.disabled", True)
|
2137
|
+
else:
|
2138
|
+
options.set_preference("pdfjs.disabled", False)
|
2126
2139
|
if firefox_arg:
|
2127
2140
|
# Can be a comma-separated list of Firefox args
|
2128
2141
|
firefox_arg_list = firefox_arg.split(",")
|
@@ -2188,6 +2201,7 @@ def get_driver(
|
|
2188
2201
|
cap_file=None,
|
2189
2202
|
cap_string=None,
|
2190
2203
|
recorder_ext=False,
|
2204
|
+
disable_cookies=False,
|
2191
2205
|
disable_js=False,
|
2192
2206
|
disable_csp=False,
|
2193
2207
|
enable_ws=False,
|
@@ -2348,6 +2362,7 @@ def get_driver(
|
|
2348
2362
|
headless
|
2349
2363
|
and (
|
2350
2364
|
proxy_auth
|
2365
|
+
or disable_cookies
|
2351
2366
|
or disable_js
|
2352
2367
|
or ad_block_on
|
2353
2368
|
or disable_csp
|
@@ -2402,6 +2417,7 @@ def get_driver(
|
|
2402
2417
|
cap_file,
|
2403
2418
|
cap_string,
|
2404
2419
|
recorder_ext,
|
2420
|
+
disable_cookies,
|
2405
2421
|
disable_js,
|
2406
2422
|
disable_csp,
|
2407
2423
|
enable_ws,
|
@@ -2459,6 +2475,7 @@ def get_driver(
|
|
2459
2475
|
multi_proxy,
|
2460
2476
|
user_agent,
|
2461
2477
|
recorder_ext,
|
2478
|
+
disable_cookies,
|
2462
2479
|
disable_js,
|
2463
2480
|
disable_csp,
|
2464
2481
|
enable_ws,
|
@@ -2520,6 +2537,7 @@ def get_remote_driver(
|
|
2520
2537
|
cap_file,
|
2521
2538
|
cap_string,
|
2522
2539
|
recorder_ext,
|
2540
|
+
disable_cookies,
|
2523
2541
|
disable_js,
|
2524
2542
|
disable_csp,
|
2525
2543
|
enable_ws,
|
@@ -2656,6 +2674,7 @@ def get_remote_driver(
|
|
2656
2674
|
multi_proxy,
|
2657
2675
|
user_agent,
|
2658
2676
|
recorder_ext,
|
2677
|
+
disable_cookies,
|
2659
2678
|
disable_js,
|
2660
2679
|
disable_csp,
|
2661
2680
|
enable_ws,
|
@@ -2751,10 +2770,12 @@ def get_remote_driver(
|
|
2751
2770
|
proxy_bypass_list,
|
2752
2771
|
proxy_pac_url,
|
2753
2772
|
user_agent,
|
2773
|
+
disable_cookies,
|
2754
2774
|
disable_js,
|
2755
2775
|
disable_csp,
|
2756
2776
|
firefox_arg,
|
2757
2777
|
firefox_pref,
|
2778
|
+
external_pdf,
|
2758
2779
|
)
|
2759
2780
|
capabilities = webdriver.FirefoxOptions().to_capabilities()
|
2760
2781
|
capabilities["marionette"] = True
|
@@ -2829,6 +2850,7 @@ def get_remote_driver(
|
|
2829
2850
|
multi_proxy,
|
2830
2851
|
user_agent,
|
2831
2852
|
recorder_ext,
|
2853
|
+
disable_cookies,
|
2832
2854
|
disable_js,
|
2833
2855
|
disable_csp,
|
2834
2856
|
enable_ws,
|
@@ -2949,6 +2971,7 @@ def get_local_driver(
|
|
2949
2971
|
multi_proxy,
|
2950
2972
|
user_agent,
|
2951
2973
|
recorder_ext,
|
2974
|
+
disable_cookies,
|
2952
2975
|
disable_js,
|
2953
2976
|
disable_csp,
|
2954
2977
|
enable_ws,
|
@@ -3030,10 +3053,12 @@ def get_local_driver(
|
|
3030
3053
|
proxy_bypass_list,
|
3031
3054
|
proxy_pac_url,
|
3032
3055
|
user_agent,
|
3056
|
+
disable_cookies,
|
3033
3057
|
disable_js,
|
3034
3058
|
disable_csp,
|
3035
3059
|
firefox_arg,
|
3036
3060
|
firefox_pref,
|
3061
|
+
external_pdf,
|
3037
3062
|
)
|
3038
3063
|
if LOCAL_GECKODRIVER and os.path.exists(LOCAL_GECKODRIVER):
|
3039
3064
|
try:
|
@@ -3386,6 +3411,8 @@ def get_local_driver(
|
|
3386
3411
|
prefs["intl.accept_languages"] = locale_code
|
3387
3412
|
if block_images:
|
3388
3413
|
prefs["profile.managed_default_content_settings.images"] = 2
|
3414
|
+
if disable_cookies:
|
3415
|
+
prefs["profile.default_content_setting_values.cookies"] = 2
|
3389
3416
|
if disable_js:
|
3390
3417
|
prefs["profile.managed_default_content_settings.javascript"] = 2
|
3391
3418
|
if do_not_track:
|
@@ -3796,6 +3823,7 @@ def get_local_driver(
|
|
3796
3823
|
multi_proxy,
|
3797
3824
|
user_agent,
|
3798
3825
|
recorder_ext,
|
3826
|
+
disable_cookies,
|
3799
3827
|
disable_js,
|
3800
3828
|
disable_csp,
|
3801
3829
|
enable_ws,
|
@@ -4321,6 +4349,7 @@ def get_local_driver(
|
|
4321
4349
|
None, # multi_proxy
|
4322
4350
|
None, # user_agent
|
4323
4351
|
None, # recorder_ext
|
4352
|
+
disable_cookies,
|
4324
4353
|
disable_js,
|
4325
4354
|
disable_csp,
|
4326
4355
|
enable_ws,
|
@@ -4563,6 +4592,7 @@ def get_local_driver(
|
|
4563
4592
|
None, # multi_proxy
|
4564
4593
|
None, # user_agent
|
4565
4594
|
None, # recorder_ext
|
4595
|
+
disable_cookies,
|
4566
4596
|
disable_js,
|
4567
4597
|
disable_csp,
|
4568
4598
|
enable_ws,
|
@@ -3760,6 +3760,7 @@ class BaseCase(unittest.TestCase):
|
|
3760
3760
|
cap_file=None,
|
3761
3761
|
cap_string=None,
|
3762
3762
|
recorder_ext=None,
|
3763
|
+
disable_cookies=None,
|
3763
3764
|
disable_js=None,
|
3764
3765
|
disable_csp=None,
|
3765
3766
|
enable_ws=None,
|
@@ -3820,6 +3821,7 @@ class BaseCase(unittest.TestCase):
|
|
3820
3821
|
cap_file - the file containing desired capabilities for the browser
|
3821
3822
|
cap_string - the string with desired capabilities for the browser
|
3822
3823
|
recorder_ext - the option to enable the SBase Recorder extension
|
3824
|
+
disable_cookies - the option to disable Cookies (May break things!)
|
3823
3825
|
disable_js - the option to disable JavaScript (May break websites!)
|
3824
3826
|
disable_csp - an option to disable Chrome's Content Security Policy
|
3825
3827
|
enable_ws - the option to enable the Web Security feature (Chrome)
|
@@ -3918,6 +3920,8 @@ class BaseCase(unittest.TestCase):
|
|
3918
3920
|
user_agent = self.user_agent
|
3919
3921
|
if recorder_ext is None:
|
3920
3922
|
recorder_ext = self.recorder_ext
|
3923
|
+
if disable_cookies is None:
|
3924
|
+
disable_cookies = self.disable_cookies
|
3921
3925
|
if disable_js is None:
|
3922
3926
|
disable_js = self.disable_js
|
3923
3927
|
if disable_csp is None:
|
@@ -4029,6 +4033,7 @@ class BaseCase(unittest.TestCase):
|
|
4029
4033
|
cap_file=cap_file,
|
4030
4034
|
cap_string=cap_string,
|
4031
4035
|
recorder_ext=recorder_ext,
|
4036
|
+
disable_cookies=disable_cookies,
|
4032
4037
|
disable_js=disable_js,
|
4033
4038
|
disable_csp=disable_csp,
|
4034
4039
|
enable_ws=enable_ws,
|
@@ -14394,6 +14399,7 @@ class BaseCase(unittest.TestCase):
|
|
14394
14399
|
elif self.record_sleep and not self.recorder_mode:
|
14395
14400
|
self.recorder_mode = True
|
14396
14401
|
self.recorder_ext = True
|
14402
|
+
self.disable_cookies = sb_config.disable_cookies
|
14397
14403
|
self.disable_js = sb_config.disable_js
|
14398
14404
|
self.disable_csp = sb_config.disable_csp
|
14399
14405
|
self.disable_ws = sb_config.disable_ws
|
@@ -14772,6 +14778,7 @@ class BaseCase(unittest.TestCase):
|
|
14772
14778
|
cap_file=self.cap_file,
|
14773
14779
|
cap_string=self.cap_string,
|
14774
14780
|
recorder_ext=self.recorder_ext,
|
14781
|
+
disable_cookies=self.disable_cookies,
|
14775
14782
|
disable_js=self.disable_js,
|
14776
14783
|
disable_csp=self.disable_csp,
|
14777
14784
|
enable_ws=self.enable_ws,
|
@@ -81,7 +81,8 @@ def Driver(
|
|
81
81
|
cap_file=None, # The desired capabilities to use with a Selenium Grid.
|
82
82
|
cap_string=None, # The desired capabilities to use with a Selenium Grid.
|
83
83
|
recorder_ext=None, # Enables the SeleniumBase Recorder Chromium extension.
|
84
|
-
|
84
|
+
disable_cookies=None, # Disable Cookies on websites. (Pages might break!)
|
85
|
+
disable_js=None, # Disable JavaScript on websites. (Pages might break!)
|
85
86
|
disable_csp=None, # Disable the Content Security Policy of websites.
|
86
87
|
enable_ws=None, # Enable Web Security on Chromium-based browsers.
|
87
88
|
disable_ws=None, # Reverse of "enable_ws". (None and False are different)
|
@@ -172,7 +173,8 @@ def Driver(
|
|
172
173
|
cap_file (str): The desired capabilities to use with a Selenium Grid.
|
173
174
|
cap_string (str): The desired capabilities to use with a Selenium Grid.
|
174
175
|
recorder_ext (bool): Enables the SeleniumBase Recorder Chromium extension.
|
175
|
-
|
176
|
+
disable_cookies (bool): Disable Cookies on websites. (Pages might break!)
|
177
|
+
disable_js (bool): Disable JavaScript on websites. (Pages might break!)
|
176
178
|
disable_csp (bool): Disable the Content Security Policy of websites.
|
177
179
|
enable_ws (bool): Enable Web Security on Chromium-based browsers.
|
178
180
|
disable_ws (bool): Reverse of "enable_ws". (None and False are different)
|
@@ -646,6 +648,11 @@ def Driver(
|
|
646
648
|
use_auto_ext = True
|
647
649
|
else:
|
648
650
|
use_auto_ext = False
|
651
|
+
if disable_cookies is None:
|
652
|
+
if "--disable-cookies" in sys_argv:
|
653
|
+
disable_cookies = True
|
654
|
+
else:
|
655
|
+
disable_cookies = False
|
649
656
|
if disable_js is None:
|
650
657
|
if "--disable-js" in sys_argv:
|
651
658
|
disable_js = True
|
@@ -772,6 +779,7 @@ def Driver(
|
|
772
779
|
cap_file=cap_file,
|
773
780
|
cap_string=cap_string,
|
774
781
|
recorder_ext=recorder_ext,
|
782
|
+
disable_cookies=disable_cookies,
|
775
783
|
disable_js=disable_js,
|
776
784
|
disable_csp=disable_csp,
|
777
785
|
enable_ws=enable_ws,
|
@@ -90,6 +90,7 @@ def pytest_addoption(parser):
|
|
90
90
|
--rec-behave (Same as Recorder Mode, but also generates behave-gherkin.)
|
91
91
|
--rec-sleep (If the Recorder is enabled, also records self.sleep calls.)
|
92
92
|
--rec-print (If the Recorder is enabled, prints output after tests end.)
|
93
|
+
--disable-cookies (Disable Cookies on websites. Pages might break!)
|
93
94
|
--disable-js (Disable JavaScript on websites. Pages might break!)
|
94
95
|
--disable-csp (Disable the Content Security Policy of websites.)
|
95
96
|
--disable-ws (Disable Web Security on Chromium-based browsers.)
|
@@ -992,6 +993,15 @@ def pytest_addoption(parser):
|
|
992
993
|
help="""The option to disable JavaScript on web pages.
|
993
994
|
Warning: Most web pages will stop working!""",
|
994
995
|
)
|
996
|
+
parser.addoption(
|
997
|
+
"--disable_cookies",
|
998
|
+
"--disable-cookies",
|
999
|
+
action="store_true",
|
1000
|
+
dest="disable_cookies",
|
1001
|
+
default=False,
|
1002
|
+
help="""The option to disable Cookies on web pages.
|
1003
|
+
Warning: Several pages may stop working!""",
|
1004
|
+
)
|
995
1005
|
parser.addoption(
|
996
1006
|
"--disable_csp",
|
997
1007
|
"--disable-csp",
|
@@ -1628,6 +1638,7 @@ def pytest_configure(config):
|
|
1628
1638
|
elif sb_config.record_sleep and not sb_config.recorder_mode:
|
1629
1639
|
sb_config.recorder_mode = True
|
1630
1640
|
sb_config.recorder_ext = True
|
1641
|
+
sb_config.disable_cookies = config.getoption("disable_cookies")
|
1631
1642
|
sb_config.disable_js = config.getoption("disable_js")
|
1632
1643
|
sb_config.disable_csp = config.getoption("disable_csp")
|
1633
1644
|
sb_config.disable_ws = config.getoption("disable_ws")
|
@@ -47,7 +47,8 @@ def SB(
|
|
47
47
|
cap_file=None, # The desired capabilities to use with a Selenium Grid.
|
48
48
|
cap_string=None, # The desired capabilities to use with a Selenium Grid.
|
49
49
|
recorder_ext=None, # Enables the SeleniumBase Recorder Chromium extension.
|
50
|
-
|
50
|
+
disable_cookies=None, # Disable Cookies on websites. (Pages might break!)
|
51
|
+
disable_js=None, # Disable JavaScript on websites. (Pages might break!)
|
51
52
|
disable_csp=None, # Disable the Content Security Policy of websites.
|
52
53
|
enable_ws=None, # Enable Web Security on Chromium-based browsers.
|
53
54
|
enable_sync=None, # Enable "Chrome Sync" on websites.
|
@@ -166,7 +167,8 @@ def SB(
|
|
166
167
|
cap_file (str): The desired capabilities to use with a Selenium Grid.
|
167
168
|
cap_string (str): The desired capabilities to use with a Selenium Grid.
|
168
169
|
recorder_ext (bool): Enables the SeleniumBase Recorder Chromium extension.
|
169
|
-
|
170
|
+
disable_cookies (bool): Disable Cookies on websites. (Pages might break!)
|
171
|
+
disable_js (bool): Disable JavaScript on websites. (Pages might break!)
|
170
172
|
disable_csp (bool): Disable the Content Security Policy of websites.
|
171
173
|
enable_ws (bool): Enable Web Security on Chromium-based browsers.
|
172
174
|
enable_sync (bool): Enable "Chrome Sync" on websites.
|
@@ -739,6 +741,11 @@ def SB(
|
|
739
741
|
use_auto_ext = True
|
740
742
|
else:
|
741
743
|
use_auto_ext = False
|
744
|
+
if disable_cookies is None:
|
745
|
+
if "--disable-cookies" in sys_argv:
|
746
|
+
disable_cookies = True
|
747
|
+
else:
|
748
|
+
disable_cookies = False
|
742
749
|
if disable_js is None:
|
743
750
|
if "--disable-js" in sys_argv:
|
744
751
|
disable_js = True
|
@@ -973,6 +980,7 @@ def SB(
|
|
973
980
|
sb_config.log_cdp_events = log_cdp_events
|
974
981
|
sb_config.no_sandbox = None
|
975
982
|
sb_config.disable_gpu = None
|
983
|
+
sb_config.disable_cookies = disable_cookies
|
976
984
|
sb_config.disable_js = disable_js
|
977
985
|
sb_config._multithreaded = False
|
978
986
|
sb_config.reuse_session = False
|
@@ -1081,6 +1089,7 @@ def SB(
|
|
1081
1089
|
sb.log_cdp_events = sb_config.log_cdp_events
|
1082
1090
|
sb.no_sandbox = sb_config.no_sandbox
|
1083
1091
|
sb.disable_gpu = sb_config.disable_gpu
|
1092
|
+
sb.disable_cookies = sb_config.disable_cookies
|
1084
1093
|
sb.disable_js = sb_config.disable_js
|
1085
1094
|
sb._multithreaded = sb_config._multithreaded
|
1086
1095
|
sb._reuse_session = sb_config.reuse_session
|
@@ -69,6 +69,7 @@ class SeleniumBrowser(Plugin):
|
|
69
69
|
--rec-behave (Same as Recorder Mode, but also generates behave-gherkin.)
|
70
70
|
--rec-sleep (If the Recorder is enabled, also records self.sleep calls.)
|
71
71
|
--rec-print (If the Recorder is enabled, prints output after tests end.)
|
72
|
+
--disable-cookies (Disable Cookies on websites. Pages might break!)
|
72
73
|
--disable-js (Disable JavaScript on websites. Pages might break!)
|
73
74
|
--disable-csp (Disable the Content Security Policy of websites.)
|
74
75
|
--disable-ws (Disable Web Security on Chromium-based browsers.)
|
@@ -710,6 +711,15 @@ class SeleniumBrowser(Plugin):
|
|
710
711
|
help="""The option to disable JavaScript on web pages.
|
711
712
|
Warning: Most web pages will stop working!""",
|
712
713
|
)
|
714
|
+
parser.addoption(
|
715
|
+
"--disable_cookies",
|
716
|
+
"--disable-cookies",
|
717
|
+
action="store_true",
|
718
|
+
dest="disable_cookies",
|
719
|
+
default=False,
|
720
|
+
help="""The option to disable Cookies on web pages.
|
721
|
+
Warning: Several pages may stop working!""",
|
722
|
+
)
|
713
723
|
parser.addoption(
|
714
724
|
"--disable_csp",
|
715
725
|
"--disable-csp",
|
@@ -1230,6 +1240,7 @@ class SeleniumBrowser(Plugin):
|
|
1230
1240
|
elif self.options.record_sleep:
|
1231
1241
|
test.test.recorder_mode = True
|
1232
1242
|
test.test.recorder_ext = True
|
1243
|
+
test.test.disable_cookies = self.options.disable_cookies
|
1233
1244
|
test.test.disable_js = self.options.disable_js
|
1234
1245
|
test.test.disable_csp = self.options.disable_csp
|
1235
1246
|
test.test.disable_ws = self.options.disable_ws
|
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.1
|
2
2
|
Name: seleniumbase
|
3
|
-
Version: 4.31.
|
3
|
+
Version: 4.31.3
|
4
4
|
Summary: A complete web automation framework for end-to-end testing.
|
5
5
|
Home-page: https://github.com/seleniumbase/SeleniumBase
|
6
6
|
Author: Michael Mintz
|
@@ -110,7 +110,7 @@ Requires-Dist: beautifulsoup4==4.12.3
|
|
110
110
|
Requires-Dist: pyotp==2.9.0
|
111
111
|
Requires-Dist: markdown-it-py==3.0.0
|
112
112
|
Requires-Dist: mdurl==0.1.2
|
113
|
-
Requires-Dist: rich==13.
|
113
|
+
Requires-Dist: rich==13.9.1
|
114
114
|
Requires-Dist: python-xlib==0.33; platform_system == "Linux"
|
115
115
|
Requires-Dist: pyreadline3>=3.5.3; platform_system == "Windows"
|
116
116
|
Requires-Dist: setuptools~=70.2; python_version < "3.10"
|
@@ -849,6 +849,7 @@ pytest test_coffee_cart.py --trace
|
|
849
849
|
--rec-behave # (Same as Recorder Mode, but also generates behave-gherkin.)
|
850
850
|
--rec-sleep # (If the Recorder is enabled, also records self.sleep calls.)
|
851
851
|
--rec-print # (If the Recorder is enabled, prints output after tests end.)
|
852
|
+
--disable-cookies # (Disable Cookies on websites. Pages might break!)
|
852
853
|
--disable-js # (Disable JavaScript on websites. Pages might break!)
|
853
854
|
--disable-csp # (Disable the Content Security Policy of websites.)
|
854
855
|
--disable-ws # (Disable Web Security on Chromium-based browsers.)
|
@@ -3,10 +3,10 @@ sbase/__main__.py,sha256=G0bVB1-DM4PGwQ1KyOupaWCs4ePbChZNNWuX2htim5U,647
|
|
3
3
|
sbase/steps.py,sha256=bKT_u5bJkKzYWEuAXi9NVVRYYxQRCM1_YJUrNFFRVPY,42865
|
4
4
|
seleniumbase/__init__.py,sha256=pXetYtgSNEM2KRcZedpSSqE52Kr3spkOD6DjZO1Wsu4,2236
|
5
5
|
seleniumbase/__main__.py,sha256=dn1p6dgCchmcH1zzTzzQvFwwdQQqnTGH6ULV9m4hv24,654
|
6
|
-
seleniumbase/__version__.py,sha256=
|
6
|
+
seleniumbase/__version__.py,sha256=s6WHbeSfAMxF9PkCW7XQeQd6kauHWK1xIlY2Gx2ZHcc,46
|
7
7
|
seleniumbase/behave/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
8
8
|
seleniumbase/behave/behave_helper.py,sha256=elkl8P9eLulRAioLstE9baYNM9N_PHBmAOcajX-pH_Y,24198
|
9
|
-
seleniumbase/behave/behave_sb.py,sha256=
|
9
|
+
seleniumbase/behave/behave_sb.py,sha256=UDEXex2GkvEok0_FCn-auIREn9OIG6Pc6zVy9S0gtUs,59516
|
10
10
|
seleniumbase/behave/steps.py,sha256=8-N-NB2tnDsxaP4LSg-uSBgbwZYMS6ZEL1oggO1PCoU,390
|
11
11
|
seleniumbase/common/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
12
12
|
seleniumbase/common/decorators.py,sha256=LJnAgg0RG3kDOFb8tpyq1zjmpv9ks6Tjg8GwgIn1YuY,7633
|
@@ -36,7 +36,7 @@ seleniumbase/console_scripts/sb_print.py,sha256=yo641b_OdSE0GUauOyxk-QrNeIjYzbRY
|
|
36
36
|
seleniumbase/console_scripts/sb_recorder.py,sha256=QazacANTQgoc76abAfFUV0d4ja1o-bbsoX9sTPZr_eg,11134
|
37
37
|
seleniumbase/core/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
38
38
|
seleniumbase/core/application_manager.py,sha256=e_0sjtI8cjY5BNyZj1QBR0j6_oCScxGmSXYEpcYwuZE,576
|
39
|
-
seleniumbase/core/browser_launcher.py,sha256=
|
39
|
+
seleniumbase/core/browser_launcher.py,sha256=WgZ71cY5gWUcejDClBBpWGgYbZdcLkGGGt0OGgKQLGk,205979
|
40
40
|
seleniumbase/core/capabilities_parser.py,sha256=meIS2uHapTCq2ldfNAToC7r0cKmZDRXuYNKExM1GHDY,6038
|
41
41
|
seleniumbase/core/colored_traceback.py,sha256=DrRWfg7XEnKcgY59Xj7Jdk09H-XqHYBSUpB-DiZt6iY,2020
|
42
42
|
seleniumbase/core/create_db_tables.sql,sha256=VWPtrdiW_HQ6yETHjqTu-VIrTwvd8I8o1NfBeaVSHpU,972
|
@@ -64,7 +64,7 @@ seleniumbase/extensions/disable_csp.zip,sha256=YMifIIgEBiLrEFrS1sfW4Exh4br1V4oK1
|
|
64
64
|
seleniumbase/extensions/recorder.zip,sha256=OOyzF-Ize2cSRu1CqhzSAq5vusI9hqLLd2OIApUHesI,11918
|
65
65
|
seleniumbase/extensions/sbase_ext.zip,sha256=3s1N8zrVaMz8RQEOIoBzC3KDjtmHwVZRvVsX25Odr_s,8175
|
66
66
|
seleniumbase/fixtures/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
67
|
-
seleniumbase/fixtures/base_case.py,sha256=
|
67
|
+
seleniumbase/fixtures/base_case.py,sha256=i9THSRjehtSs8eRjUvOQLm0AVZrzCrJ2q0K7Ui5AHTY,702683
|
68
68
|
seleniumbase/fixtures/constants.py,sha256=TapuGLdERtvZPGMblVXkNGybr8tj8FMtN3sbJ3ygyoc,13569
|
69
69
|
seleniumbase/fixtures/css_to_xpath.py,sha256=9ouDB1xl4MJ2os6JOgTIAyHKOQfuxtxvXC3O5hSnEKA,1954
|
70
70
|
seleniumbase/fixtures/errors.py,sha256=KyxuEVx_e3MPhVrJfNIa_3ltMpbCFxfy_jxK8RFNTns,555
|
@@ -85,13 +85,13 @@ seleniumbase/plugins/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hS
|
|
85
85
|
seleniumbase/plugins/base_plugin.py,sha256=FemdftNhOaTfQIw5bWcJQPPPGQ3P0_sMEI_YYDuzZgU,14972
|
86
86
|
seleniumbase/plugins/basic_test_info.py,sha256=8ov6n417gPbqqvrlT4zrch7l2XcRt-GF2ny6rR9AMWk,2108
|
87
87
|
seleniumbase/plugins/db_reporting_plugin.py,sha256=En09qUCoojrk9-vbcnsoHdSELoGmag2GDIyu3jTiJas,7331
|
88
|
-
seleniumbase/plugins/driver_manager.py,sha256=
|
88
|
+
seleniumbase/plugins/driver_manager.py,sha256=elGPayydGWkiChDOEl3VrAgWvq_9HiwLGO4u4L59jBY,33725
|
89
89
|
seleniumbase/plugins/page_source.py,sha256=loTnXxOj4kxEukuTZEiGyvKBhY3KDVDMnNlHHheTBDE,1889
|
90
|
-
seleniumbase/plugins/pytest_plugin.py,sha256=
|
90
|
+
seleniumbase/plugins/pytest_plugin.py,sha256=DSQiHFFuhd8Je_71vDvbGvR5hmFUHoO2EMzbUlirJbQ,97538
|
91
91
|
seleniumbase/plugins/s3_logging_plugin.py,sha256=WDfertQgGOW_SRJpFMaekYD6vBVW9VO62POtXXy2HCM,2319
|
92
|
-
seleniumbase/plugins/sb_manager.py,sha256=
|
92
|
+
seleniumbase/plugins/sb_manager.py,sha256=XNk24ZSHqBsX-NzEcu100GcIihfu3-DC3KcktBJu_mE,53438
|
93
93
|
seleniumbase/plugins/screen_shots.py,sha256=1hrXw-hzuZ1BR6Yh7AyWX2ABnvnP73-RCbwdz958gj4,1127
|
94
|
-
seleniumbase/plugins/selenium_plugin.py,sha256=
|
94
|
+
seleniumbase/plugins/selenium_plugin.py,sha256=_i6lrzJB7tL-1pStryXrOC07XPnEJruF3fsiy4WmRwM,59048
|
95
95
|
seleniumbase/resources/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
96
96
|
seleniumbase/translate/__init__.py,sha256=N2i5XntTwJZmwr9-qvdX5gC6Rdm5-ClIbnQ8yyPn4Oo,459
|
97
97
|
seleniumbase/translate/chinese.py,sha256=0QhK2eadtsdN4KCvwki1J7jBCe8I4xxWbKzteJKJozY,24698
|
@@ -126,9 +126,9 @@ seleniumbase/utilities/selenium_grid/start-grid-hub.bat,sha256=Ftq-GrAKRYH2ssDPr
|
|
126
126
|
seleniumbase/utilities/selenium_grid/start-grid-hub.sh,sha256=KADv0RUHONLL2_I443QFK8PryBpDmKn5Gy0s4o0vDSM,106
|
127
127
|
seleniumbase/utilities/selenium_ide/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
128
128
|
seleniumbase/utilities/selenium_ide/convert_ide.py,sha256=pZFnqEJQEKZPyNFjkLD29s2HPQgCrWW9XJWpCPhWOoM,31691
|
129
|
-
seleniumbase-4.31.
|
130
|
-
seleniumbase-4.31.
|
131
|
-
seleniumbase-4.31.
|
132
|
-
seleniumbase-4.31.
|
133
|
-
seleniumbase-4.31.
|
134
|
-
seleniumbase-4.31.
|
129
|
+
seleniumbase-4.31.3.dist-info/LICENSE,sha256=odSYtWibXBnQ1gBg6CnDZ82n8kLF_if5-2nbqnEyD8k,1085
|
130
|
+
seleniumbase-4.31.3.dist-info/METADATA,sha256=bf6SWfCW_NrVFwyNiFnsd8dz_nP-z0cBmX11Co3_m88,85315
|
131
|
+
seleniumbase-4.31.3.dist-info/WHEEL,sha256=GV9aMThwP_4oNCtvEC2ec3qUYutgWeAzklro_0m4WJQ,91
|
132
|
+
seleniumbase-4.31.3.dist-info/entry_points.txt,sha256=CNrh2EKNaHYEhO6pP1RJyVLB99LkDDYX7TnUK8xfjqk,623
|
133
|
+
seleniumbase-4.31.3.dist-info/top_level.txt,sha256=4N97aBOQ8ETCnDnokBsWb07lJfTaq3C1ZzYRxvLMxqU,19
|
134
|
+
seleniumbase-4.31.3.dist-info/RECORD,,
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|