Commit 90150929 authored by Mark Lapierre's avatar Mark Lapierre

Retry select user/group in approval rule

There is a transient bug that stops loading the dropdown content.
This retries the attempt to filter so that it tries to load the content
again (up to 3 times)

See https://gitlab.com/gitlab-org/gitlab/-/issues/288297
parent c5200338
...@@ -33,10 +33,10 @@ module QA ...@@ -33,10 +33,10 @@ module QA
fill_element :approvals_required_field, rule[:approvals_required] fill_element :approvals_required_field, rule[:approvals_required]
rule.key?(:users) && rule[:users].each do |user| rule.key?(:users) && rule[:users].each do |user|
select_user_member user.username select_user_member(user.username)
end end
rule.key?(:groups) && rule[:groups].each do |group| rule.key?(:groups) && rule[:groups].each do |group|
select_group_member group.name select_group_member(group.name)
end end
click_approvers_modal_ok_button click_approvers_modal_ok_button
...@@ -65,6 +65,7 @@ module QA ...@@ -65,6 +65,7 @@ module QA
private private
def enter_member(name) def enter_member(name)
retry_until do
within_element(:member_select_field) do within_element(:member_select_field) do
search_item(name) search_item(name)
end end
...@@ -75,4 +76,5 @@ module QA ...@@ -75,4 +76,5 @@ module QA
end end
end end
end end
end
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