Commit 014c9ec0 authored by Desiree Chevalier's avatar Desiree Chevalier

Add wait in e2e when adding MR approvers

parent 69304a32
...@@ -5,6 +5,8 @@ module QA ...@@ -5,6 +5,8 @@ module QA
module Page module Page
module MergeRequest module MergeRequest
module New module New
include QA::Page::Component::Select2
def self.prepended(page) def self.prepended(page)
page.module_eval do page.module_eval do
view 'ee/app/assets/javascripts/approvals/components/app.vue' do view 'ee/app/assets/javascripts/approvals/components/app.vue' do
...@@ -60,7 +62,7 @@ module QA ...@@ -60,7 +62,7 @@ module QA
def enter_member(name) def enter_member(name)
within_element(:member_select_field) do within_element(:member_select_field) do
find(".select2-input").set(name) search_item(name)
end end
end end
end end
......
...@@ -18,10 +18,14 @@ module QA ...@@ -18,10 +18,14 @@ module QA
end end
end end
def search_and_select(item_text) def search_item(item_text)
find('.select2-input').set(item_text) find('.select2-input').set(item_text)
wait_for_search_to_complete wait_for_search_to_complete
end
def search_and_select(item_text)
search_item(item_text)
select_item(item_text) select_item(item_text)
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