diff options
Diffstat (limited to 'service/test/functional/features/steps/tag_list.py')
-rw-r--r-- | service/test/functional/features/steps/tag_list.py | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/service/test/functional/features/steps/tag_list.py b/service/test/functional/features/steps/tag_list.py index 443c5173..35b03513 100644 --- a/service/test/functional/features/steps/tag_list.py +++ b/service/test/functional/features/steps/tag_list.py @@ -17,20 +17,20 @@ from common import * def click_first_element_with_class(context, classname): - elements = context.browser.find_elements_by_class_name(classname) - elements[0].click() + element = find_element_by_class_name(context, classname) + element.click() def is_side_nav_expanded(context): - e = context.browser.find_elements_by_class_name('content')[0].get_attribute('class').count(u'move-right') == 1 - return e + e = find_element_by_class_name(context, 'content') + return u'move-right' in e.get_attribute("class") def expand_side_nav(context): if is_side_nav_expanded(context): return - toggle = context.browser.find_elements_by_class_name('side-nav-toggle')[0] + toggle = find_element_by_class_name(context, 'side-nav-toggle') toggle.click() @@ -39,7 +39,7 @@ def impl(context, tag): wait_for_user_alert_to_disapear(context) expand_side_nav(context) - wait_until_element_is_visible_by_locator(context, (By.ID, 'tag-%s' % tag), 20) + wait_until_element_is_visible_by_locator(context, (By.ID, 'tag-%s' % tag), timeout=20) e = find_element_by_id(context, 'tag-%s' % tag) e.click() |