Commit c6548dc3 authored by Desiree Chevalier's avatar Desiree Chevalier Committed by Walmyr Lima e Silva Filho

Remove uses of click_body in e2e specs

parent c6631e6b
......@@ -35,7 +35,8 @@ module QA
def add_issue_to_epic(issue_url)
find_element(:issue_actions_split_button).find('button', text: 'Add an issue').click
fill_element :add_issue_input, issue_url
click_body
# Clicking the title blurs the input
click_element :title
click_element :add_issue_button
end
......
......@@ -255,12 +255,6 @@ module QA
click_link text
end
def click_body
wait_for_requests
find('body').click
end
def visit_link_in_element(name)
visit find_element(name)['href']
end
......
......@@ -34,6 +34,10 @@ module QA
has_css?('.select2-active', wait: 1)
has_no_css?('.select2-active', wait: 30)
end
def dropdown_open?
has_css?('.select2-input')
end
end
end
end
......
......@@ -124,7 +124,7 @@ module QA
end
end
click_body
click_element(:edit_link_labels)
labels.each do |label|
has_element?(:labels_block, text: label)
......
......@@ -32,8 +32,7 @@ module QA
def choose_namespace(namespace)
retry_on_exception do
click_body
click_element :project_namespace_select
click_element :project_namespace_select unless dropdown_open?
search_and_select(namespace)
end
end
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment