Skip to content
代码片段 群组 项目
提交 4bfa51b1 编辑于 作者: nwestbury's avatar nwestbury
浏览文件

Add retry to load of artifacts page

上级 0335e0c4
No related branches found
No related tags found
无相关合并请求
...@@ -9,8 +9,10 @@ class Show < QA::Page::Base ...@@ -9,8 +9,10 @@ class Show < QA::Page::Base
element :directory_name_link element :directory_name_link
end end
def go_to_directory(name) def go_to_directory(name, retry_attempts = 1)
click_element(:directory_name_link, directory_name: name) retry_on_exception(max_attempts: retry_attempts, reload: true, sleep_interval: 10) do
click_element(:directory_name_link, directory_name: name)
end
end end
end end
end end
......
...@@ -80,6 +80,8 @@ module QA ...@@ -80,6 +80,8 @@ module QA
end end
it 'replicates the job artifact to the secondary Geo site', testcase: 'https://gitlab.com/gitlab-org/quality/testcases/-/quality/test_cases/1658' do it 'replicates the job artifact to the secondary Geo site', testcase: 'https://gitlab.com/gitlab-org/quality/testcases/-/quality/test_cases/1658' do
artifact_page_retry_attempts = 12
Runtime::Logger.debug('Visiting the secondary Geo site') Runtime::Logger.debug('Visiting the secondary Geo site')
Flow::Login.while_signed_in(address: :geo_secondary) do Flow::Login.while_signed_in(address: :geo_secondary) do
...@@ -107,7 +109,7 @@ module QA ...@@ -107,7 +109,7 @@ module QA
end end
Page::Project::Artifact::Show.perform do |artifact| Page::Project::Artifact::Show.perform do |artifact|
artifact.go_to_directory(@directory_name) artifact.go_to_directory(@directory_name, artifact_page_retry_attempts)
expect(artifact).to have_content(@file_name) expect(artifact).to have_content(@file_name)
end end
end end
......
0% 加载中 .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册