Skip to content
Snippets Groups Projects
Commit 9120b946 authored by Sanad Liaquat's avatar Sanad Liaquat Committed by Chloe Liu
Browse files

E2E: Refactor out wait_for_gitlab_to_respond and call after SS toggle

parent b425af1a
No related branches found
No related tags found
2 merge requests!123340E2E: Refactor out wait_for_gitlab_to_respond and call after SS toggle,!119439Draft: Prevent file variable content expansion in downstream pipeline
......@@ -259,13 +259,10 @@ def sign_in_using_gitlab_credentials(user:, skip_page_validation: false)
wait_for_gitlab_to_respond
Page::Main::Menu.perform(&:enable_new_navigation) if Runtime::Env.super_sidebar_enabled?
Page::Main::Menu.validate_elements_present! unless skip_page_validation
end
def wait_for_gitlab_to_respond
wait_until(sleep_interval: 5, message: '502 - GitLab is taking too much time to respond') do
has_no_text?('GitLab is taking too much time to respond')
end
wait_for_gitlab_to_respond
Page::Main::Menu.validate_elements_present! unless skip_page_validation
end
def fill_in_credential(user)
......
......@@ -39,6 +39,12 @@ def finished_loading?(wait: DEFAULT_MAX_WAIT_TIME)
Capybara.page.has_no_css?('.gl-spinner', wait: wait)
end
end
def wait_for_gitlab_to_respond
Waiter.wait_until(sleep_interval: 5, message: '502 - GitLab is taking too much time to respond') do
Capybara.page.has_no_text?('GitLab is taking too much time to respond')
end
end
end
end
end
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment