Merge pull request #3629 from seleniumbase/shortcuts-and-dependencies
Shortcuts and dependencies
This commit is contained in:
commit
413a762e6b
|
@ -3,7 +3,7 @@
|
||||||
|
|
||||||
regex>=2024.11.6
|
regex>=2024.11.6
|
||||||
pymdown-extensions>=10.14.3
|
pymdown-extensions>=10.14.3
|
||||||
pipdeptree>=2.25.1
|
pipdeptree>=2.26.0
|
||||||
python-dateutil>=2.8.2
|
python-dateutil>=2.8.2
|
||||||
Markdown==3.7
|
Markdown==3.7
|
||||||
click==8.1.8
|
click==8.1.8
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
pip>=25.0.1
|
pip>=25.0.1
|
||||||
packaging>=24.2
|
packaging>=24.2
|
||||||
setuptools~=70.2;python_version<"3.10"
|
setuptools~=70.2;python_version<"3.10"
|
||||||
setuptools>=77.0.3;python_version>="3.10"
|
setuptools>=78.0.2;python_version>="3.10"
|
||||||
wheel>=0.45.1
|
wheel>=0.45.1
|
||||||
attrs>=25.3.0
|
attrs>=25.3.0
|
||||||
certifi>=2025.1.31
|
certifi>=2025.1.31
|
||||||
|
@ -28,7 +28,7 @@ pyyaml>=6.0.2
|
||||||
pygments>=2.19.1
|
pygments>=2.19.1
|
||||||
pyreadline3>=3.5.3;platform_system=="Windows"
|
pyreadline3>=3.5.3;platform_system=="Windows"
|
||||||
tabcompleter>=1.4.0
|
tabcompleter>=1.4.0
|
||||||
pdbp>=1.6.1
|
pdbp>=1.7.0
|
||||||
idna==3.10
|
idna==3.10
|
||||||
chardet==5.2.0
|
chardet==5.2.0
|
||||||
charset-normalizer==3.4.1
|
charset-normalizer==3.4.1
|
||||||
|
|
|
@ -1,2 +1,2 @@
|
||||||
# seleniumbase package
|
# seleniumbase package
|
||||||
__version__ = "4.36.1"
|
__version__ = "4.36.2"
|
||||||
|
|
|
@ -3993,6 +3993,7 @@ class BaseCase(unittest.TestCase):
|
||||||
d_width=None,
|
d_width=None,
|
||||||
d_height=None,
|
d_height=None,
|
||||||
d_p_r=None,
|
d_p_r=None,
|
||||||
|
**kwargs,
|
||||||
):
|
):
|
||||||
"""This method spins up an extra browser for tests that require
|
"""This method spins up an extra browser for tests that require
|
||||||
more than one. The first browser is already provided by tests
|
more than one. The first browser is already provided by tests
|
||||||
|
@ -4081,6 +4082,11 @@ class BaseCase(unittest.TestCase):
|
||||||
" for examples!)"
|
" for examples!)"
|
||||||
% (browserstack_ref, sauce_labs_ref)
|
% (browserstack_ref, sauce_labs_ref)
|
||||||
)
|
)
|
||||||
|
shortcuts = ["dark", "guest", "locale", "mobile", "pls", "uc", "wire"]
|
||||||
|
if kwargs:
|
||||||
|
for key in kwargs.keys():
|
||||||
|
if key not in shortcuts:
|
||||||
|
raise TypeError("Unexpected keyword argument '%s'" % key)
|
||||||
if browser is None:
|
if browser is None:
|
||||||
browser = self.browser
|
browser = self.browser
|
||||||
browser_name = browser
|
browser_name = browser
|
||||||
|
@ -4088,6 +4094,8 @@ class BaseCase(unittest.TestCase):
|
||||||
headless = self.headless
|
headless = self.headless
|
||||||
if locale_code is None:
|
if locale_code is None:
|
||||||
locale_code = self.locale_code
|
locale_code = self.locale_code
|
||||||
|
if "locale" in kwargs and not locale_code:
|
||||||
|
locale_code = kwargs["locale"]
|
||||||
if protocol is None:
|
if protocol is None:
|
||||||
protocol = self.protocol
|
protocol = self.protocol
|
||||||
if servername is None:
|
if servername is None:
|
||||||
|
@ -4130,6 +4138,8 @@ class BaseCase(unittest.TestCase):
|
||||||
uc_cdp_events = self.uc_cdp_events
|
uc_cdp_events = self.uc_cdp_events
|
||||||
if uc_subprocess is None:
|
if uc_subprocess is None:
|
||||||
uc_subprocess = self.uc_subprocess
|
uc_subprocess = self.uc_subprocess
|
||||||
|
if "uc" in kwargs and not undetectable:
|
||||||
|
undetectable = kwargs["uc"]
|
||||||
if log_cdp_events is None:
|
if log_cdp_events is None:
|
||||||
log_cdp_events = self.log_cdp_events
|
log_cdp_events = self.log_cdp_events
|
||||||
if no_sandbox is None:
|
if no_sandbox is None:
|
||||||
|
@ -4144,8 +4154,12 @@ class BaseCase(unittest.TestCase):
|
||||||
incognito = self.incognito
|
incognito = self.incognito
|
||||||
if guest_mode is None:
|
if guest_mode is None:
|
||||||
guest_mode = self.guest_mode
|
guest_mode = self.guest_mode
|
||||||
|
if "guest" in kwargs and not guest_mode:
|
||||||
|
guest_mode = kwargs["guest"]
|
||||||
if dark_mode is None:
|
if dark_mode is None:
|
||||||
dark_mode = self.dark_mode
|
dark_mode = self.dark_mode
|
||||||
|
if "dark" in kwargs and not dark_mode:
|
||||||
|
dark_mode = kwargs["dark"]
|
||||||
if devtools is None:
|
if devtools is None:
|
||||||
devtools = self.devtools
|
devtools = self.devtools
|
||||||
if remote_debug is None:
|
if remote_debug is None:
|
||||||
|
@ -4182,8 +4196,12 @@ class BaseCase(unittest.TestCase):
|
||||||
driver_version = self.driver_version
|
driver_version = self.driver_version
|
||||||
if page_load_strategy is None:
|
if page_load_strategy is None:
|
||||||
page_load_strategy = self.page_load_strategy
|
page_load_strategy = self.page_load_strategy
|
||||||
|
if "pls" in kwargs and not page_load_strategy:
|
||||||
|
page_load_strategy = kwargs["pls"]
|
||||||
if use_wire is None:
|
if use_wire is None:
|
||||||
use_wire = self.use_wire
|
use_wire = self.use_wire
|
||||||
|
if "wire" in kwargs and not use_wire:
|
||||||
|
use_wire = kwargs["wire"]
|
||||||
if external_pdf is None:
|
if external_pdf is None:
|
||||||
external_pdf = self.external_pdf
|
external_pdf = self.external_pdf
|
||||||
test_id = self.__get_test_id()
|
test_id = self.__get_test_id()
|
||||||
|
@ -4193,6 +4211,8 @@ class BaseCase(unittest.TestCase):
|
||||||
cap_string = self.cap_string
|
cap_string = self.cap_string
|
||||||
if is_mobile is None:
|
if is_mobile is None:
|
||||||
is_mobile = self.mobile_emulator
|
is_mobile = self.mobile_emulator
|
||||||
|
if "mobile" in kwargs and not is_mobile:
|
||||||
|
is_mobile = kwargs["mobile"]
|
||||||
if d_width is None:
|
if d_width is None:
|
||||||
d_width = self.__device_width
|
d_width = self.__device_width
|
||||||
if d_height is None:
|
if d_height is None:
|
||||||
|
|
6
setup.py
6
setup.py
|
@ -150,7 +150,7 @@ setup(
|
||||||
'pip>=25.0.1',
|
'pip>=25.0.1',
|
||||||
'packaging>=24.2',
|
'packaging>=24.2',
|
||||||
'setuptools~=70.2;python_version<"3.10"', # Newer ones had issues
|
'setuptools~=70.2;python_version<"3.10"', # Newer ones had issues
|
||||||
'setuptools>=77.0.3;python_version>="3.10"',
|
'setuptools>=78.0.2;python_version>="3.10"',
|
||||||
'wheel>=0.45.1',
|
'wheel>=0.45.1',
|
||||||
'attrs>=25.3.0',
|
'attrs>=25.3.0',
|
||||||
"certifi>=2025.1.31",
|
"certifi>=2025.1.31",
|
||||||
|
@ -177,7 +177,7 @@ setup(
|
||||||
'pygments>=2.19.1',
|
'pygments>=2.19.1',
|
||||||
'pyreadline3>=3.5.3;platform_system=="Windows"',
|
'pyreadline3>=3.5.3;platform_system=="Windows"',
|
||||||
"tabcompleter>=1.4.0",
|
"tabcompleter>=1.4.0",
|
||||||
"pdbp>=1.6.1",
|
"pdbp>=1.7.0",
|
||||||
"idna==3.10",
|
"idna==3.10",
|
||||||
'chardet==5.2.0',
|
'chardet==5.2.0',
|
||||||
'charset-normalizer==3.4.1',
|
'charset-normalizer==3.4.1',
|
||||||
|
@ -259,7 +259,7 @@ setup(
|
||||||
# pip install -e .[pdfminer]
|
# pip install -e .[pdfminer]
|
||||||
# (An optional library for parsing PDF files.)
|
# (An optional library for parsing PDF files.)
|
||||||
"pdfminer": [
|
"pdfminer": [
|
||||||
'pdfminer.six==20240706',
|
'pdfminer.six==20250324',
|
||||||
'cryptography==39.0.2;python_version<"3.9"',
|
'cryptography==39.0.2;python_version<"3.9"',
|
||||||
'cryptography==44.0.2;python_version>="3.9"',
|
'cryptography==44.0.2;python_version>="3.9"',
|
||||||
'cffi==1.17.1',
|
'cffi==1.17.1',
|
||||||
|
|
Loading…
Reference in New Issue