seleniumbase 4.35.0__py3-none-any.whl → 4.35.1__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/console_scripts/sb_mkdir.py +3 -0
- seleniumbase/core/sb_cdp.py +20 -10
- seleniumbase/fixtures/js_utils.py +2 -0
- seleniumbase/plugins/driver_manager.py +2 -2
- seleniumbase/plugins/pytest_plugin.py +3 -0
- seleniumbase/plugins/sb_manager.py +1 -1
- {seleniumbase-4.35.0.dist-info → seleniumbase-4.35.1.dist-info}/METADATA +2 -2
- {seleniumbase-4.35.0.dist-info → seleniumbase-4.35.1.dist-info}/RECORD +13 -13
- {seleniumbase-4.35.0.dist-info → seleniumbase-4.35.1.dist-info}/LICENSE +0 -0
- {seleniumbase-4.35.0.dist-info → seleniumbase-4.35.1.dist-info}/WHEEL +0 -0
- {seleniumbase-4.35.0.dist-info → seleniumbase-4.35.1.dist-info}/entry_points.txt +0 -0
- {seleniumbase-4.35.0.dist-info → seleniumbase-4.35.1.dist-info}/top_level.txt +0 -0
seleniumbase/__version__.py
CHANGED
@@ -1,2 +1,2 @@
|
|
1
1
|
# seleniumbase package
|
2
|
-
__version__ = "4.35.
|
2
|
+
__version__ = "4.35.1"
|
@@ -631,10 +631,13 @@ def main():
|
|
631
631
|
data = []
|
632
632
|
data.append("from seleniumbase import BaseCase")
|
633
633
|
data.append("from .google_objects import HomePage, ResultsPage")
|
634
|
+
data.append('BaseCase.main(__name__, __file__, "--uc")')
|
634
635
|
data.append("")
|
635
636
|
data.append("")
|
636
637
|
data.append("class GoogleTests(BaseCase):")
|
637
638
|
data.append(" def test_google_dot_com(self):")
|
639
|
+
data.append(" if not self.undetectable:")
|
640
|
+
data.append(" self.get_new_driver(undetectable=True)")
|
638
641
|
data.append(' self.open("https://google.com/ncr")')
|
639
642
|
data.append(' self.assert_title_contains("Google")')
|
640
643
|
data.append(" self.sleep(0.05)")
|
seleniumbase/core/sb_cdp.py
CHANGED
@@ -288,7 +288,7 @@ class CDPMethods():
|
|
288
288
|
return updated_elements
|
289
289
|
|
290
290
|
def select(self, selector, timeout=None):
|
291
|
-
"""Similar to find_element()
|
291
|
+
"""Similar to find_element()."""
|
292
292
|
if not timeout:
|
293
293
|
timeout = settings.SMALL_TIMEOUT
|
294
294
|
self.__add_light_pause()
|
@@ -297,12 +297,25 @@ class CDPMethods():
|
|
297
297
|
tag_name = selector.split(":contains(")[0].split(" ")[-1]
|
298
298
|
text = selector.split(":contains(")[1].split(")")[0][1:-1]
|
299
299
|
with suppress(Exception):
|
300
|
+
new_timeout = timeout
|
301
|
+
if new_timeout < 1:
|
302
|
+
new_timeout = 1
|
300
303
|
self.loop.run_until_complete(
|
301
|
-
self.page.select(tag_name, timeout=
|
304
|
+
self.page.select(tag_name, timeout=new_timeout)
|
302
305
|
)
|
303
|
-
self.loop.run_until_complete(
|
304
|
-
|
305
|
-
|
306
|
+
self.loop.run_until_complete(
|
307
|
+
self.page.find(text, timeout=new_timeout)
|
308
|
+
)
|
309
|
+
elements = self.find_elements_by_text(text, tag_name=tag_name)
|
310
|
+
if not elements:
|
311
|
+
plural = "s"
|
312
|
+
if timeout == 1:
|
313
|
+
plural = ""
|
314
|
+
msg = "\n Element {%s} was not found after %s second%s!"
|
315
|
+
message = msg % (selector, timeout, plural)
|
316
|
+
raise Exception(message)
|
317
|
+
element = self.__add_sync_methods(elements[0])
|
318
|
+
return element
|
306
319
|
failure = False
|
307
320
|
try:
|
308
321
|
element = self.loop.run_until_complete(
|
@@ -313,11 +326,8 @@ class CDPMethods():
|
|
313
326
|
plural = "s"
|
314
327
|
if timeout == 1:
|
315
328
|
plural = ""
|
316
|
-
|
317
|
-
|
318
|
-
timeout,
|
319
|
-
plural,
|
320
|
-
)
|
329
|
+
msg = "\n Element {%s} was not found after %s second%s!"
|
330
|
+
message = msg % (selector, timeout, plural)
|
321
331
|
if failure:
|
322
332
|
raise Exception(message)
|
323
333
|
element = self.__add_sync_methods(element)
|
@@ -950,6 +950,8 @@ def post_message(driver, message, msg_dur=None, style="info"):
|
|
950
950
|
set_messenger_theme(driver)
|
951
951
|
try:
|
952
952
|
execute_script(driver, messenger_script)
|
953
|
+
except TypeError:
|
954
|
+
pass
|
953
955
|
except Exception:
|
954
956
|
time.sleep(0.17)
|
955
957
|
activate_messenger(driver)
|
@@ -10,7 +10,7 @@ Example -->
|
|
10
10
|
```python
|
11
11
|
from seleniumbase import DriverContext
|
12
12
|
|
13
|
-
with DriverContext() as driver:
|
13
|
+
with DriverContext(uc=True) as driver:
|
14
14
|
driver.get("https://google.com/ncr")
|
15
15
|
```
|
16
16
|
|
@@ -30,7 +30,7 @@ Example -->
|
|
30
30
|
```python
|
31
31
|
from seleniumbase import Driver
|
32
32
|
|
33
|
-
driver = Driver()
|
33
|
+
driver = Driver(uc=True)
|
34
34
|
driver.get("https://google.com/ncr")
|
35
35
|
```
|
36
36
|
|
@@ -2496,6 +2496,9 @@ def pytest_unconfigure(config):
|
|
2496
2496
|
"""This runs after all tests have completed with pytest."""
|
2497
2497
|
if "--co" in sys_argv or "--collect-only" in sys_argv:
|
2498
2498
|
return
|
2499
|
+
reporter = config.pluginmanager.get_plugin("terminalreporter")
|
2500
|
+
if not hasattr(reporter, "_sessionstarttime"):
|
2501
|
+
return
|
2499
2502
|
if hasattr(sb_config, "_multithreaded") and sb_config._multithreaded:
|
2500
2503
|
import fasteners
|
2501
2504
|
|
@@ -10,7 +10,7 @@ Example -->
|
|
10
10
|
```python
|
11
11
|
from seleniumbase import SB
|
12
12
|
|
13
|
-
with SB() as sb: # Many args! Eg. SB(browser="edge")
|
13
|
+
with SB(uc=True) as sb: # Many args! Eg. SB(browser="edge")
|
14
14
|
sb.open("https://google.com/ncr")
|
15
15
|
sb.type('[name="q"]', "SeleniumBase on GitHub\n")
|
16
16
|
sb.click('a[href*="github.com/seleniumbase"]')
|
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.2
|
2
2
|
Name: seleniumbase
|
3
|
-
Version: 4.35.
|
3
|
+
Version: 4.35.1
|
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
|
@@ -265,7 +265,7 @@ Dynamic: summary
|
|
265
265
|
```python
|
266
266
|
from seleniumbase import SB
|
267
267
|
|
268
|
-
with SB(test=True) as sb:
|
268
|
+
with SB(test=True, uc=True) as sb:
|
269
269
|
sb.open("https://google.com/ncr")
|
270
270
|
sb.type('[title="Search"]', "SeleniumBase GitHub page\n")
|
271
271
|
sb.click('[href*="github.com/seleniumbase/"]')
|
@@ -3,7 +3,7 @@ sbase/__main__.py,sha256=G0bVB1-DM4PGwQ1KyOupaWCs4ePbChZNNWuX2htim5U,647
|
|
3
3
|
sbase/steps.py,sha256=_WvAjydKqZfTdnZW9LPKkRty-g-lfdUPmLqnZj6ulcs,43013
|
4
4
|
seleniumbase/__init__.py,sha256=OtJh8nGKL4xtZpw8KPqmn7Q6R-86t4cWUDyVF5MbMTo,2398
|
5
5
|
seleniumbase/__main__.py,sha256=dn1p6dgCchmcH1zzTzzQvFwwdQQqnTGH6ULV9m4hv24,654
|
6
|
-
seleniumbase/__version__.py,sha256=
|
6
|
+
seleniumbase/__version__.py,sha256=Db8lU-34AfPk_0zWgBNe5iBhYA1JOuCwJ1W2-rdR45g,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
9
|
seleniumbase/behave/behave_sb.py,sha256=qQF85LoohJBfrPK5ZcPi50v-pWtOrC9qcN1B3Ki_3tY,59401
|
@@ -27,7 +27,7 @@ seleniumbase/console_scripts/sb_caseplans.py,sha256=qlmvjQ49bOBE1Q29fVmabimkVibC
|
|
27
27
|
seleniumbase/console_scripts/sb_commander.py,sha256=exQGKzqRAoGqRmQtDmlmoHnSG9eSy9eh8HVy-tXw6s4,13343
|
28
28
|
seleniumbase/console_scripts/sb_install.py,sha256=RdByOmTQebibRFk5ym-FtFr0Gf91_ZfOsBB2MN5izUc,55524
|
29
29
|
seleniumbase/console_scripts/sb_mkchart.py,sha256=ep9g-9CSIwaOJKVxhB3xjRQpfsuApyN8-Dr129cNXwQ,10941
|
30
|
-
seleniumbase/console_scripts/sb_mkdir.py,sha256=
|
30
|
+
seleniumbase/console_scripts/sb_mkdir.py,sha256=iFN6ZMOgmH_GAvEuvzYltWuYiS3PRFQcL5fJIj1yX_Y,30897
|
31
31
|
seleniumbase/console_scripts/sb_mkfile.py,sha256=OWYd4yFccmjrd-gNn1t1una-HDRU2_N2-r4Tg3nHsj0,17744
|
32
32
|
seleniumbase/console_scripts/sb_mkpres.py,sha256=EWFRVacjYTX49y-fEiYTZacM9_01IxuuaO4nMjHrIGo,11015
|
33
33
|
seleniumbase/console_scripts/sb_mkrec.py,sha256=PrizjTmyrROYPO0yDm-zQS3QSfsZNeAmcJKKUvfgLhc,11966
|
@@ -50,7 +50,7 @@ seleniumbase/core/proxy_helper.py,sha256=4VkpMwavz0fx8wcOqJ_jyBT0HIXwcxmAcpd1gjJ
|
|
50
50
|
seleniumbase/core/recorder_helper.py,sha256=fNGjbapXmEsht54x1o6Igk198QdnPxDDnjUOzQxNhNQ,25055
|
51
51
|
seleniumbase/core/report_helper.py,sha256=AIl6Qava2yW1uSzbLpJBlPlYDz0KE-rVhogh8hsGWBo,12201
|
52
52
|
seleniumbase/core/s3_manager.py,sha256=bkeI8I4y19ebWuQG1oEZV5qJbotC6eN8vin31OCNWJk,3521
|
53
|
-
seleniumbase/core/sb_cdp.py,sha256=
|
53
|
+
seleniumbase/core/sb_cdp.py,sha256=rfMcBNGY90qfusHyTJzexWk6wHv9GTH9klQspgxENHE,81554
|
54
54
|
seleniumbase/core/sb_driver.py,sha256=yvTDRblBzG6bDX7XcLiAA6QcBelSJj_HHL_04lcfeeE,13760
|
55
55
|
seleniumbase/core/session_helper.py,sha256=s9zD3PVZEWVzG2h81cCUskbNWLfdjC_LwwQjKptHCak,558
|
56
56
|
seleniumbase/core/settings_parser.py,sha256=gqVohHVlE_5L5Cqe2L24uYrRzvoK-saX8E_Df7_-_3I,7609
|
@@ -69,7 +69,7 @@ seleniumbase/fixtures/base_case.py,sha256=ncejN3q7m6_GHQTASuy4LHkeeCn829RRZN4lRB
|
|
69
69
|
seleniumbase/fixtures/constants.py,sha256=WMrItuNyKq3XVJ64NluLIRc4gJCxDw8K8qXED0b9S2w,13752
|
70
70
|
seleniumbase/fixtures/css_to_xpath.py,sha256=9ouDB1xl4MJ2os6JOgTIAyHKOQfuxtxvXC3O5hSnEKA,1954
|
71
71
|
seleniumbase/fixtures/errors.py,sha256=KyxuEVx_e3MPhVrJfNIa_3ltMpbCFxfy_jxK8RFNTns,555
|
72
|
-
seleniumbase/fixtures/js_utils.py,sha256=
|
72
|
+
seleniumbase/fixtures/js_utils.py,sha256=Ykt019DFP8S27o8Kai_ihT01qQWo3RqHUeljqOEUdFU,52247
|
73
73
|
seleniumbase/fixtures/page_actions.py,sha256=LPcFSkUvBkxLrOt4laQHHN-NLmqInT41E2vlPiOlLFY,66753
|
74
74
|
seleniumbase/fixtures/page_utils.py,sha256=H1iV8f9vDyEy87DBntyiBXC_tg8HskcebUOAJVn0hxE,12160
|
75
75
|
seleniumbase/fixtures/shared_utils.py,sha256=G6CsE-Adt-GfuZF-71jXWKSIQW7YZPx8FIM24pVd_yI,8368
|
@@ -86,11 +86,11 @@ seleniumbase/plugins/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hS
|
|
86
86
|
seleniumbase/plugins/base_plugin.py,sha256=ItLgtaZmu_363iycy8BNX0Do5LyIWGiTMLW6krXM-WQ,14748
|
87
87
|
seleniumbase/plugins/basic_test_info.py,sha256=8ov6n417gPbqqvrlT4zrch7l2XcRt-GF2ny6rR9AMWk,2108
|
88
88
|
seleniumbase/plugins/db_reporting_plugin.py,sha256=En09qUCoojrk9-vbcnsoHdSELoGmag2GDIyu3jTiJas,7331
|
89
|
-
seleniumbase/plugins/driver_manager.py,sha256=
|
89
|
+
seleniumbase/plugins/driver_manager.py,sha256=UqWDnhOFB7GNftaSAqWFsR76vOyeaqMc0JqQKiAw3lU,35877
|
90
90
|
seleniumbase/plugins/page_source.py,sha256=loTnXxOj4kxEukuTZEiGyvKBhY3KDVDMnNlHHheTBDE,1889
|
91
|
-
seleniumbase/plugins/pytest_plugin.py,sha256=
|
91
|
+
seleniumbase/plugins/pytest_plugin.py,sha256=952AIyaH-PdmNksoeXjzhXxoc8Z53yV-WPjlrHhp2OM,108382
|
92
92
|
seleniumbase/plugins/s3_logging_plugin.py,sha256=WDfertQgGOW_SRJpFMaekYD6vBVW9VO62POtXXy2HCM,2319
|
93
|
-
seleniumbase/plugins/sb_manager.py,sha256=
|
93
|
+
seleniumbase/plugins/sb_manager.py,sha256=9hWfSA2DGclgQ2QMJISR8k_rF53NCMGcQbr-K5eh5Dg,56249
|
94
94
|
seleniumbase/plugins/screen_shots.py,sha256=1hrXw-hzuZ1BR6Yh7AyWX2ABnvnP73-RCbwdz958gj4,1127
|
95
95
|
seleniumbase/plugins/selenium_plugin.py,sha256=y0eNco8T4KgGLProLPHPLw479QH5lRms4wqwOnTgkSc,60081
|
96
96
|
seleniumbase/resources/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
@@ -135,9 +135,9 @@ seleniumbase/utilities/selenium_grid/start-grid-hub.bat,sha256=Ftq-GrAKRYH2ssDPr
|
|
135
135
|
seleniumbase/utilities/selenium_grid/start-grid-hub.sh,sha256=KADv0RUHONLL2_I443QFK8PryBpDmKn5Gy0s4o0vDSM,106
|
136
136
|
seleniumbase/utilities/selenium_ide/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
137
137
|
seleniumbase/utilities/selenium_ide/convert_ide.py,sha256=pZFnqEJQEKZPyNFjkLD29s2HPQgCrWW9XJWpCPhWOoM,31691
|
138
|
-
seleniumbase-4.35.
|
139
|
-
seleniumbase-4.35.
|
140
|
-
seleniumbase-4.35.
|
141
|
-
seleniumbase-4.35.
|
142
|
-
seleniumbase-4.35.
|
143
|
-
seleniumbase-4.35.
|
138
|
+
seleniumbase-4.35.1.dist-info/LICENSE,sha256=BRblZsX7HyPUjQmYTiyWr_e9tzWvmR3R4SFclM2R3W0,1085
|
139
|
+
seleniumbase-4.35.1.dist-info/METADATA,sha256=-RJH6DIDAyALXSl9bXjwxbJQQhMoqi0BBjtb_vTVmCI,86530
|
140
|
+
seleniumbase-4.35.1.dist-info/WHEEL,sha256=In9FTNxeP60KnTkGw7wk6mJPYd_dQSjEZmXdBdMCI-8,91
|
141
|
+
seleniumbase-4.35.1.dist-info/entry_points.txt,sha256=CNrh2EKNaHYEhO6pP1RJyVLB99LkDDYX7TnUK8xfjqk,623
|
142
|
+
seleniumbase-4.35.1.dist-info/top_level.txt,sha256=4N97aBOQ8ETCnDnokBsWb07lJfTaq3C1ZzYRxvLMxqU,19
|
143
|
+
seleniumbase-4.35.1.dist-info/RECORD,,
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|