diff options
author | Petr Vobornik <pvoborni@redhat.com> | 2014-04-14 14:10:20 +0200 |
---|---|---|
committer | Petr Vobornik <pvoborni@redhat.com> | 2014-06-10 10:23:25 +0200 |
commit | c7af2458091ba95eccc26f4468234413e8b016b9 (patch) | |
tree | 4ced522bf92ac2c38a9726a0c441c713d63068cb /ipatests/test_webui/ui_driver.py | |
parent | fc0926ba91f57cb5cd182f2edf50f24d4cfd7432 (diff) | |
download | freeipa-c7af2458091ba95eccc26f4468234413e8b016b9.tar.gz freeipa-c7af2458091ba95eccc26f4468234413e8b016b9.tar.xz freeipa-c7af2458091ba95eccc26f4468234413e8b016b9.zip |
webui: add action dropdown
Reviewed-By: Endi Sukma Dewata <edewata@redhat.com>
Diffstat (limited to 'ipatests/test_webui/ui_driver.py')
-rw-r--r-- | ipatests/test_webui/ui_driver.py | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/ipatests/test_webui/ui_driver.py b/ipatests/test_webui/ui_driver.py index 553e2472b..b57acab1f 100644 --- a/ipatests/test_webui/ui_driver.py +++ b/ipatests/test_webui/ui_driver.py @@ -1368,14 +1368,18 @@ class UI_driver(object): for key in pkeys: self.assert_record(key, parent, table_name, negative=True) - def action_list_action(self, name): + def action_list_action(self, name, confirm=True, confirm_btn="ok"): """ Execute action list action """ - cont = self.find(".active-facet .facet-action-list", By.CSS_SELECTOR, strict=True) - select = self.find("select[name=action]", By.CSS_SELECTOR, cont, strict=True) - Select(select).select_by_value(name) - self.button_click('apply', cont) + cont = self.find(".active-facet .facet-actions", By.CSS_SELECTOR, strict=True) + expand = self.find(".dropdown-toggle", By.CSS_SELECTOR, cont, strict=True) + expand.click() + action_link = self.find("li[data-name=%s] a" % name, By.CSS_SELECTOR, cont, strict=True) + action_link.click() + if confirm: + self.wait(0.5) # wait for dialog + self.dialog_button_click(confirm_btn) self.wait() def action_panel_action(self, panel_name, action): |