diff options
Diffstat (limited to 'bitbake/lib/toaster/tests/browser/selenium_helpers_base.py')
-rw-r--r-- | bitbake/lib/toaster/tests/browser/selenium_helpers_base.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/bitbake/lib/toaster/tests/browser/selenium_helpers_base.py b/bitbake/lib/toaster/tests/browser/selenium_helpers_base.py index 22d4085b24..2725f13382 100644 --- a/bitbake/lib/toaster/tests/browser/selenium_helpers_base.py +++ b/bitbake/lib/toaster/tests/browser/selenium_helpers_base.py | |||
@@ -230,12 +230,15 @@ class SeleniumTestCaseBase(unittest.TestCase): | |||
230 | 230 | ||
231 | def wait_until_clickable(self, selector, poll=1): | 231 | def wait_until_clickable(self, selector, poll=1): |
232 | """ Wait until element matching CSS selector is visible on the page """ | 232 | """ Wait until element matching CSS selector is visible on the page """ |
233 | sel = selector | ||
234 | if sel.startswith('#'): | ||
235 | sel = selector[1:] | ||
233 | WebDriverWait( | 236 | WebDriverWait( |
234 | self.driver, | 237 | self.driver, |
235 | Wait._TIMEOUT, | 238 | Wait._TIMEOUT, |
236 | poll_frequency=poll | 239 | poll_frequency=poll |
237 | ).until( | 240 | ).until( |
238 | EC.element_to_be_clickable((By.ID, selector.removeprefix('#') | 241 | EC.element_to_be_clickable((By.ID, sel |
239 | ) | 242 | ) |
240 | ) | 243 | ) |
241 | ) | 244 | ) |