diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2020-09-21 15:09:34 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2020-09-21 15:09:34 +0300 |
commit | 79850719759d6fe1b0682fd27573d479c9013f03 (patch) | |
tree | bc0466515aca2c2db339cfe8e44d3c148804d304 /spec/features | |
parent | d05604c95aeed1e8bbf63abc0b363cb921f0996a (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'spec/features')
-rw-r--r-- | spec/features/admin/admin_uses_repository_checks_spec.rb | 2 | ||||
-rw-r--r-- | spec/features/dashboard/todos/todos_filtering_spec.rb | 8 | ||||
-rw-r--r-- | spec/features/dashboard/todos/todos_spec.rb | 15 |
3 files changed, 24 insertions, 1 deletions
diff --git a/spec/features/admin/admin_uses_repository_checks_spec.rb b/spec/features/admin/admin_uses_repository_checks_spec.rb index b8851c28531..44642983a36 100644 --- a/spec/features/admin/admin_uses_repository_checks_spec.rb +++ b/spec/features/admin/admin_uses_repository_checks_spec.rb @@ -46,7 +46,7 @@ RSpec.describe 'Admin uses repository checks', :request_store, :clean_gitlab_red ) visit_admin_project_page(project) - page.within('.alert') do + page.within('.gl-alert') do expect(page.text).to match(/Last repository check \(just now\) failed/) end end diff --git a/spec/features/dashboard/todos/todos_filtering_spec.rb b/spec/features/dashboard/todos/todos_filtering_spec.rb index f60b07c976e..b1464af4194 100644 --- a/spec/features/dashboard/todos/todos_filtering_spec.rb +++ b/spec/features/dashboard/todos/todos_filtering_spec.rb @@ -130,6 +130,7 @@ RSpec.describe 'Dashboard > User filters todos', :js do before do create(:todo, :build_failed, user: user_1, author: user_2, project: project_1) create(:todo, :marked, user: user_1, author: user_2, project: project_1, target: issue1) + create(:todo, :review_requested, user: user_1, author: user_2, project: project_1, target: issue1) end it 'filters by Assigned' do @@ -138,6 +139,12 @@ RSpec.describe 'Dashboard > User filters todos', :js do expect_to_see_action(:assigned) end + it 'filters by Review Requested' do + filter_action('Review requested') + + expect_to_see_action(:review_requested) + end + it 'filters by Mentioned' do filter_action('Mentioned') @@ -168,6 +175,7 @@ RSpec.describe 'Dashboard > User filters todos', :js do def expect_to_see_action(action_name) action_names = { assigned: ' assigned you ', + review_requested: ' requested a review of ', mentioned: ' mentioned ', marked: ' added a todo for ', build_failed: ' build failed for ' diff --git a/spec/features/dashboard/todos/todos_spec.rb b/spec/features/dashboard/todos/todos_spec.rb index cf773d2caed..7243b5d3483 100644 --- a/spec/features/dashboard/todos/todos_spec.rb +++ b/spec/features/dashboard/todos/todos_spec.rb @@ -197,6 +197,21 @@ RSpec.describe 'Dashboard Todos' do end end end + + context 'review request todo' do + let(:merge_request) { create(:merge_request, title: "Fixes issue") } + + before do + create(:todo, :review_requested, user: user, project: project, target: merge_request, author: user) + visit dashboard_todos_path + end + + it 'shows you set yourself as an reviewer message' do + page.within('.js-todos-all') do + expect(page).to have_content("You requested a review of merge request #{merge_request.to_reference} \"Fixes issue\" at #{project.namespace.owner_name} / #{project.name} from yourself") + end + end + end end context 'User has done todos', :js do |