bcpkgfox 0.16.65__tar.gz → 0.16.66__tar.gz
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.
Potentially problematic release.
This version of bcpkgfox might be problematic. Click here for more details.
- {bcpkgfox-0.16.65 → bcpkgfox-0.16.66}/PKG-INFO +1 -1
- {bcpkgfox-0.16.65 → bcpkgfox-0.16.66}/bcpkgfox/__init__.py +5 -4
- {bcpkgfox-0.16.65 → bcpkgfox-0.16.66}/bcpkgfox.egg-info/PKG-INFO +1 -1
- {bcpkgfox-0.16.65 → bcpkgfox-0.16.66}/setup.py +1 -1
- {bcpkgfox-0.16.65 → bcpkgfox-0.16.66}/README.md +0 -0
- {bcpkgfox-0.16.65 → bcpkgfox-0.16.66}/bcpkgfox/clean.py +0 -0
- {bcpkgfox-0.16.65 → bcpkgfox-0.16.66}/bcpkgfox/cli.py +0 -0
- {bcpkgfox-0.16.65 → bcpkgfox-0.16.66}/bcpkgfox/find_elements.py +0 -0
- {bcpkgfox-0.16.65 → bcpkgfox-0.16.66}/bcpkgfox/get_driver.py +0 -0
- {bcpkgfox-0.16.65 → bcpkgfox-0.16.66}/bcpkgfox/invoke_api.py +0 -0
- {bcpkgfox-0.16.65 → bcpkgfox-0.16.66}/bcpkgfox/system.py +0 -0
- {bcpkgfox-0.16.65 → bcpkgfox-0.16.66}/bcpkgfox.egg-info/SOURCES.txt +0 -0
- {bcpkgfox-0.16.65 → bcpkgfox-0.16.66}/bcpkgfox.egg-info/dependency_links.txt +0 -0
- {bcpkgfox-0.16.65 → bcpkgfox-0.16.66}/bcpkgfox.egg-info/entry_points.txt +0 -0
- {bcpkgfox-0.16.65 → bcpkgfox-0.16.66}/bcpkgfox.egg-info/requires.txt +0 -0
- {bcpkgfox-0.16.65 → bcpkgfox-0.16.66}/bcpkgfox.egg-info/top_level.txt +0 -0
- {bcpkgfox-0.16.65 → bcpkgfox-0.16.66}/setup.cfg +0 -0
|
@@ -225,7 +225,7 @@ def wait_for_element_disappear(object, type, timeout=10):
|
|
|
225
225
|
|
|
226
226
|
return find_elements.backcode__dont_use__wait_for_d(driver, object, type, timeout=tempo)
|
|
227
227
|
|
|
228
|
-
def selectfox(elemento, method, key,
|
|
228
|
+
def selectfox(elemento, method, key, relative = None):
|
|
229
229
|
"""
|
|
230
230
|
Seleciona uma opção em um elemento <select>.
|
|
231
231
|
|
|
@@ -233,6 +233,7 @@ def selectfox(elemento, method, key, pure = None):
|
|
|
233
233
|
- elemento: Elemento <select> encontrado pelo Selenium.
|
|
234
234
|
- method: Método de seleção ('index', 'text' ou 'value').
|
|
235
235
|
- key: Valor usado na seleção (índice, texto visível ou valor do atributo 'value').
|
|
236
|
+
- relative: Ao invés de selecionar um elemento identico, seleciona um elemento que apenas contém a 'key'
|
|
236
237
|
|
|
237
238
|
- Exemplo:
|
|
238
239
|
elemento_select = bc.find_element_with_wait("xpath", '//select[@value="VALUE_DO_PRIMEIRO_SELECT"]')
|
|
@@ -264,12 +265,12 @@ def selectfox(elemento, method, key, pure = None):
|
|
|
264
265
|
if method == "text":
|
|
265
266
|
elements = select.options
|
|
266
267
|
for elm in elements:
|
|
267
|
-
if
|
|
268
|
-
if key
|
|
268
|
+
if relative:
|
|
269
|
+
if key.lower().strip() in elm.text.lower().strip():
|
|
269
270
|
select.select_by_visible_text(elm.text)
|
|
270
271
|
return
|
|
271
272
|
else:
|
|
272
|
-
if key
|
|
273
|
+
if key == elm.text:
|
|
273
274
|
select.select_by_visible_text(elm.text)
|
|
274
275
|
return
|
|
275
276
|
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|