summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlfredo Sumaran <alfredo@gitlab.com>2016-05-10 18:11:16 -0500
committerAlfredo Sumaran <alfredo@gitlab.com>2016-06-03 17:14:23 -0500
commit15108cbaac059b341eae9d733c5ff8cb1dfbdb28 (patch)
treeb994c5b54e30f7ee8b2eb1b804850fbbad9f1b6b
parent812ae973db7f6fa72246c975fb4eff6b1a95c886 (diff)
downloadgitlab-ce-15108cbaac059b341eae9d733c5ff8cb1dfbdb28.tar.gz
Fix spec
-rw-r--r--spec/features/issues/update_issues_spec.rb17
1 files changed, 9 insertions, 8 deletions
diff --git a/spec/features/issues/update_issues_spec.rb b/spec/features/issues/update_issues_spec.rb
index c109de1cbdb..c6181eed9af 100644
--- a/spec/features/issues/update_issues_spec.rb
+++ b/spec/features/issues/update_issues_spec.rb
@@ -42,7 +42,7 @@ feature 'Multiple issue updating from issues#index', feature: true do
visit namespace_project_issues_path(project.namespace, project)
find('#check_all_issues').click
- find('.js-update-assignee').click
+ click_update_assignee_button
find('.dropdown-menu-user-link', text: user.username).click
click_update_issues_button
@@ -57,14 +57,11 @@ feature 'Multiple issue updating from issues#index', feature: true do
visit namespace_project_issues_path(project.namespace, project)
find('#check_all_issues').click
- find('.js-update-assignee').click
+ click_update_assignee_button
click_link 'Unassigned'
click_update_issues_button
- sleep 1 # needed
- page.within first('.issue .controls') do
- expect(page).to have_no_selector('.author_link')
- end
+ expect(find('.issue:first-child .controls')).not_to have_css('.author_link')
end
end
@@ -95,8 +92,7 @@ feature 'Multiple issue updating from issues#index', feature: true do
find('.dropdown-menu-milestone a', text: "No Milestone").click
click_update_issues_button
- sleep 1 # needed
- expect(first('.issue')).to_not have_content milestone.title
+ expect(find('.issue:first-child')).to_not have_content milestone.title
end
end
@@ -112,6 +108,11 @@ feature 'Multiple issue updating from issues#index', feature: true do
create(:issue, project: project, milestone: milestone)
end
+ def click_update_assignee_button
+ find('.js-update-assignee').click
+ wait_for_ajax
+ end
+
def click_update_issues_button
find('.update_selected_issues').click
wait_for_ajax