robo_appian 0.0.6__py3-none-any.whl → 0.0.8__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.
Potentially problematic release.
This version of robo_appian might be problematic. Click here for more details.
- robo_appian/components/InputUtils.py +7 -0
- robo_appian/components/LabelUtils.py +7 -2
- robo_appian/components/LinkUtils.py +7 -7
- {robo_appian-0.0.6.dist-info → robo_appian-0.0.8.dist-info}/METADATA +1 -1
- {robo_appian-0.0.6.dist-info → robo_appian-0.0.8.dist-info}/RECORD +7 -7
- {robo_appian-0.0.6.dist-info → robo_appian-0.0.8.dist-info}/LICENSE +0 -0
- {robo_appian-0.0.6.dist-info → robo_appian-0.0.8.dist-info}/WHEEL +0 -0
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import stat
|
|
1
2
|
from numpy import size
|
|
2
3
|
from robo_appian.utils.ComponentUtils import ComponentUtils
|
|
3
4
|
from selenium.webdriver.common.by import By
|
|
@@ -105,3 +106,9 @@ class InputUtils:
|
|
|
105
106
|
def setValueByLabelText(wait: WebDriverWait, label: str, value: str):
|
|
106
107
|
input_components = InputUtils.__findInputComponentsByLabel(wait, label)
|
|
107
108
|
InputUtils.__setValueByComponents(wait, input_components, value)
|
|
109
|
+
|
|
110
|
+
@staticmethod
|
|
111
|
+
def setValueById(wait: WebDriverWait, component_id: str, value: str):
|
|
112
|
+
component = wait.until(EC.element_to_be_clickable((By.ID, component_id)))
|
|
113
|
+
InputUtils._setComponentValue(component, value)
|
|
114
|
+
return component
|
|
@@ -17,7 +17,7 @@ class LabelUtils:
|
|
|
17
17
|
"""
|
|
18
18
|
|
|
19
19
|
@staticmethod
|
|
20
|
-
def find(wait
|
|
20
|
+
def find(wait: WebDriverWait, label: str):
|
|
21
21
|
"""
|
|
22
22
|
Finds a label component by its text.
|
|
23
23
|
|
|
@@ -35,6 +35,11 @@ class LabelUtils:
|
|
|
35
35
|
# This method locates a label component that contains the specified text.
|
|
36
36
|
# It uses XPath to find the element that matches the text.
|
|
37
37
|
|
|
38
|
-
xpath = f".//*[text()='{label}']"
|
|
38
|
+
xpath = f".//*[normalize-space(text())='{label}']"
|
|
39
39
|
component = wait.until(EC.presence_of_element_located((By.XPATH, xpath)))
|
|
40
40
|
return component
|
|
41
|
+
|
|
42
|
+
@staticmethod
|
|
43
|
+
def click(wait: WebDriverWait, label: str):
|
|
44
|
+
component = LabelUtils.find(wait, label)
|
|
45
|
+
component.click()
|
|
@@ -16,6 +16,11 @@ class LinkUtils:
|
|
|
16
16
|
LinkUtils.click(wait, "Learn More")
|
|
17
17
|
|
|
18
18
|
"""
|
|
19
|
+
@staticmethod
|
|
20
|
+
def find(wait: WebDriverWait, label: str):
|
|
21
|
+
xpath = f'.//a[normalize-space(text())="{label}"]'
|
|
22
|
+
component = wait.until(EC.element_to_be_clickable((By.XPATH, xpath)))
|
|
23
|
+
return component
|
|
19
24
|
|
|
20
25
|
@staticmethod
|
|
21
26
|
def click(wait: WebDriverWait, label: str):
|
|
@@ -30,12 +35,7 @@ class LinkUtils:
|
|
|
30
35
|
Example:
|
|
31
36
|
LinkUtils.click(wait, "Learn More")
|
|
32
37
|
"""
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
# The link component is expected to have a structure where the label is within a span inside a paragraph element.
|
|
36
|
-
|
|
37
|
-
xpath = f'.//p/span[text()="{label}"]'
|
|
38
|
-
# component = wait.until(EC.presence_of_element_located((By.XPATH, xpath)) )
|
|
39
|
-
component = wait.until(EC.element_to_be_clickable((By.XPATH, xpath)))
|
|
38
|
+
|
|
39
|
+
component = LinkUtils.find(wait. label)
|
|
40
40
|
component.click()
|
|
41
41
|
return component
|
|
@@ -2,9 +2,9 @@ robo_appian/__init__.py,sha256=6u9n2W7P1IKSSr5IPGsg7LhVR1o1uYv424mXDjJLgb0,720
|
|
|
2
2
|
robo_appian/components/ButtonUtils.py,sha256=fzxVG_OWzAwwMc_L7cBE48a_aih_diMTWj4UtVfttrI,2171
|
|
3
3
|
robo_appian/components/DateUtils.py,sha256=mmvyYVgp0thiIQ2uaUiEV-aXwsyCp2d1W8hKR6j_E4M,4599
|
|
4
4
|
robo_appian/components/DropdownUtils.py,sha256=5p6Twef2dYf8Zta_SP3sIcWbaZqVI-yeMNOywHHitHw,5720
|
|
5
|
-
robo_appian/components/InputUtils.py,sha256=
|
|
6
|
-
robo_appian/components/LabelUtils.py,sha256=
|
|
7
|
-
robo_appian/components/LinkUtils.py,sha256=
|
|
5
|
+
robo_appian/components/InputUtils.py,sha256=DwsC8G7e4lVdd2wxmUfCiX_9PDf6WXQfkrPOO2mF_B4,4393
|
|
6
|
+
robo_appian/components/LabelUtils.py,sha256=cPu4p7z-5kNTxxLY4d1dMDhNtkLnNaM88Kl6ptHvvHo,1382
|
|
7
|
+
robo_appian/components/LinkUtils.py,sha256=owUUJ4-pYDf0oRV1M146kqBfBb96rH7nCK3iA_t2Mpo,1177
|
|
8
8
|
robo_appian/components/SearchInputUtils.py,sha256=WbPrsDVWnagtz1Vkj0gftf6jfTYivODEeqz2E12oXUc,2576
|
|
9
9
|
robo_appian/components/TabUtils.py,sha256=A3Zeu5Lg7JcD_c_xCtIm7Xkjm53VTLtBhzFGLyY0FoA,2058
|
|
10
10
|
robo_appian/components/TableUtils.py,sha256=CeYYmFdOD0F78UkkVXlRmrZatPr94oSVCHyGf_fgfuw,8583
|
|
@@ -15,7 +15,7 @@ robo_appian/exceptions/MyCustomError.py,sha256=DVAkytXNNQNjqyTyCjk6FFd6fr3AsBe57
|
|
|
15
15
|
robo_appian/exceptions/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
16
16
|
robo_appian/utils/ComponentUtils.py,sha256=uq1y6_DxH3O-m7vCvtdVE5640Wx8Je8ydA7pbKDrKVw,8398
|
|
17
17
|
robo_appian/utils/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
18
|
-
robo_appian-0.0.
|
|
19
|
-
robo_appian-0.0.
|
|
20
|
-
robo_appian-0.0.
|
|
21
|
-
robo_appian-0.0.
|
|
18
|
+
robo_appian-0.0.8.dist-info/LICENSE,sha256=g-xR4dRa9_4iFkMoJmED-wE-J5hoxbk3105Knhfpjm0,1068
|
|
19
|
+
robo_appian-0.0.8.dist-info/METADATA,sha256=2CuricJFVWA7LSyv6RBAqxXjjtH8HRT0cKc83zcFPTc,4104
|
|
20
|
+
robo_appian-0.0.8.dist-info/WHEEL,sha256=b4K_helf-jlQoXBBETfwnf4B04YC67LOev0jo4fX5m8,88
|
|
21
|
+
robo_appian-0.0.8.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|