|
2 | 2 | from typing import Tuple, Optional, Literal |
3 | 3 | from selenium.webdriver.common.by import By |
4 | 4 | from selenium.webdriver.remote.webelement import WebElement |
5 | | -from selenium.webdriver.support import expected_conditions as EC |
| 5 | +from selenium.webdriver.support import expected_conditions as ec |
6 | 6 | from selenium.webdriver.support.wait import WebDriverWait |
7 | 7 | from selenium.common.exceptions import ( |
8 | 8 | TimeoutException, ElementNotVisibleException |
@@ -57,10 +57,10 @@ def wait_for( |
57 | 57 | waiter = waiter or self._wait |
58 | 58 |
|
59 | 59 | conditions = { |
60 | | - "clickable": EC.element_to_be_clickable(locator), |
| 60 | + "clickable": ec.element_to_be_clickable(locator), |
61 | 61 | # Pass the locator tuple as a single argument |
62 | | - "visible": EC.visibility_of_element_located(locator), |
63 | | - "present": EC.presence_of_element_located(locator), |
| 62 | + "visible": ec.visibility_of_element_located(locator), |
| 63 | + "present": ec.presence_of_element_located(locator), |
64 | 64 | } |
65 | 65 |
|
66 | 66 | if condition not in conditions: |
@@ -89,9 +89,7 @@ def click( |
89 | 89 |
|
90 | 90 | # @log() |
91 | 91 | # @timing |
92 | | - def set( |
93 | | - self, locator: Locator, text: str, wait_type: Optional[WaitType] = None |
94 | | - ): |
| 92 | + def set(self, locator: Locator, text: str, wait_type: Optional[WaitType] = None): |
95 | 93 | """ |
96 | 94 | Set text in an input field. |
97 | 95 | """ |
|
0 commit comments