diff --git a/qa/qa/page/project/branches/show.rb b/qa/qa/page/project/branches/show.rb index 762eacdab158ef9631988a1d9e45c9ea1af10899..480fc7d78cbe28d2dbc971a2cb30e457efeb2748 100644 --- a/qa/qa/page/project/branches/show.rb +++ b/qa/qa/page/project/branches/show.rb @@ -28,9 +28,11 @@ module QA finished_loading? end - def has_no_branch?(branch_name) - within_element(:all_branches) do - has_no_element?(:branch_name, text: branch_name, wait: Support::Waiter::DEFAULT_MAX_WAIT_TIME) + def has_no_branch?(branch_name, reload: false) + wait(reload: reload) do + within_element(:all_branches) do + has_no_element?(:branch_name, text: branch_name) + end end end diff --git a/qa/qa/specs/features/browser_ui/3_create/repository/add_list_delete_branches_spec.rb b/qa/qa/specs/features/browser_ui/3_create/repository/add_list_delete_branches_spec.rb index cf6c24fa8738907a363fd7dfc04b82a097f57af8..37a784248d4040e118ed18b25bac6f47cc350cc2 100644 --- a/qa/qa/specs/features/browser_ui/3_create/repository/add_list_delete_branches_spec.rb +++ b/qa/qa/specs/features/browser_ui/3_create/repository/add_list_delete_branches_spec.rb @@ -84,7 +84,7 @@ module QA page.refresh Page::Project::Branches::Show.perform do |branches_view| - expect(branches_view).to have_no_branch(second_branch) + expect(branches_view).to have_no_branch(second_branch, reload: true) end end end