summaryrefslogtreecommitdiffstats
path: root/ipatests/test_webui
diff options
context:
space:
mode:
authorLenka Doudova <ldoudova@redhat.com>2016-02-10 16:16:22 +0100
committerPetr Vobornik <pvoborni@redhat.com>2016-02-23 10:11:22 +0100
commita3f8e8e71f95c145cbf2e1917bd71c6bedee11d4 (patch)
tree61c2cd6732bca21dd5e109be0ee58496a706f949 /ipatests/test_webui
parentd1252cfb8ef613e290a23e0e9cabd9d135a129ca (diff)
downloadfreeipa-a3f8e8e71f95c145cbf2e1917bd71c6bedee11d4.tar.gz
freeipa-a3f8e8e71f95c145cbf2e1917bd71c6bedee11d4.tar.xz
freeipa-a3f8e8e71f95c145cbf2e1917bd71c6bedee11d4.zip
WebUI tests: fix failing of tests due to unclicable label
Checkbox label is no longer clickable, most tests fail with error like this: AssertionError: Can't click on checkbox label: table.table Message: Element is not clickable at point (37, 340.3999938964844). Other element would receive the click: <input class="standalone" id="cn18" value="itest-group" name="cn" type="checkbox"> The checkbox is clickable directly without the label, this patch provides according fix. Reviewed-By: Petr Vobornik <pvoborni@redhat.com>
Diffstat (limited to 'ipatests/test_webui')
-rw-r--r--ipatests/test_webui/ui_driver.py6
1 files changed, 1 insertions, 5 deletions
diff --git a/ipatests/test_webui/ui_driver.py b/ipatests/test_webui/ui_driver.py
index fc22f8612..ad3a9100f 100644
--- a/ipatests/test_webui/ui_driver.py
+++ b/ipatests/test_webui/ui_driver.py
@@ -933,12 +933,8 @@ class UI_driver(object):
s = self.get_table_selector(table_name)
input_s = s + " tbody td input[value='%s']" % pkey
checkbox = self.find(input_s, By.CSS_SELECTOR, parent, strict=True)
- checkbox_id = checkbox.get_attribute('id')
- label_s = s + " tbody td label[for='%s']" % checkbox_id
- print(label_s)
- label = self.find(label_s, By.CSS_SELECTOR, parent, strict=True)
try:
- ActionChains(self.driver).move_to_element(label).click().perform()
+ ActionChains(self.driver).move_to_element(checkbox).click().perform()
except WebDriverException as e:
assert False, 'Can\'t click on checkbox label: %s \n%s' % (s, e)
self.wait()