diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2021-07-20 09:55:51 +0000 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2021-07-20 09:55:51 +0000 |
commit | e8d2c2579383897a1dd7f9debd359abe8ae8373d (patch) | |
tree | c42be41678c2586d49a75cabce89322082698334 /spec/features/dashboard | |
parent | fc845b37ec3a90aaa719975f607740c22ba6a113 (diff) | |
download | gitlab-ce-e8d2c2579383897a1dd7f9debd359abe8ae8373d.tar.gz |
Add latest changes from gitlab-org/gitlab@14-1-stable-eev14.1.0-rc42
Diffstat (limited to 'spec/features/dashboard')
-rw-r--r-- | spec/features/dashboard/datetime_on_tooltips_spec.rb | 1 | ||||
-rw-r--r-- | spec/features/dashboard/issues_filter_spec.rb | 4 | ||||
-rw-r--r-- | spec/features/dashboard/merge_requests_spec.rb | 2 | ||||
-rw-r--r-- | spec/features/dashboard/projects_spec.rb | 6 | ||||
-rw-r--r-- | spec/features/dashboard/root_spec.rb | 19 |
5 files changed, 24 insertions, 8 deletions
diff --git a/spec/features/dashboard/datetime_on_tooltips_spec.rb b/spec/features/dashboard/datetime_on_tooltips_spec.rb index 442b8904974..bf9f6895d24 100644 --- a/spec/features/dashboard/datetime_on_tooltips_spec.rb +++ b/spec/features/dashboard/datetime_on_tooltips_spec.rb @@ -5,6 +5,7 @@ require 'spec_helper' RSpec.describe 'Tooltips on .timeago dates', :js do let_it_be(:user) { create(:user) } let_it_be(:project) { create(:project, name: 'test', namespace: user.namespace) } + let(:created_date) { 1.day.ago.beginning_of_minute - 1.hour } before_all do diff --git a/spec/features/dashboard/issues_filter_spec.rb b/spec/features/dashboard/issues_filter_spec.rb index 4bd00bd0a80..4d59e1ded3d 100644 --- a/spec/features/dashboard/issues_filter_spec.rb +++ b/spec/features/dashboard/issues_filter_spec.rb @@ -81,14 +81,14 @@ RSpec.describe 'Dashboard Issues filtering', :js do sort_by('Created date') visit_issues(assignee_username: user.username) - expect(find('.issues-filters')).to have_content('Created date') + expect(page).to have_button('Created date') end it 'keeps sorting issues after visiting Projects Issues page' do sort_by('Created date') visit project_issues_path(project) - expect(find('.issues-filters')).to have_content('Created date') + expect(page).to have_button('Created date') end end diff --git a/spec/features/dashboard/merge_requests_spec.rb b/spec/features/dashboard/merge_requests_spec.rb index 26b376be660..aa2485d4236 100644 --- a/spec/features/dashboard/merge_requests_spec.rb +++ b/spec/features/dashboard/merge_requests_spec.rb @@ -53,6 +53,7 @@ RSpec.describe 'Dashboard Merge Requests' do context 'merge requests exist' do let_it_be(:author_user) { create(:user) } + let(:label) { create(:label) } let!(:assigned_merge_request) do @@ -181,6 +182,7 @@ RSpec.describe 'Dashboard Merge Requests' do context 'merge request review', :js do let_it_be(:author_user) { create(:user) } + let!(:review_requested_merge_request) do create(:merge_request, reviewers: [current_user], diff --git a/spec/features/dashboard/projects_spec.rb b/spec/features/dashboard/projects_spec.rb index 20c753b1cdb..1f0981de7e1 100644 --- a/spec/features/dashboard/projects_spec.rb +++ b/spec/features/dashboard/projects_spec.rb @@ -18,12 +18,6 @@ RSpec.describe 'Dashboard Projects' do end end - it 'shows the customize banner', :js do - visit dashboard_projects_path - - expect(page).to have_content('Do you want to customize this page?') - end - context 'when user has access to the project' do it 'shows role badge' do visit dashboard_projects_path diff --git a/spec/features/dashboard/root_spec.rb b/spec/features/dashboard/root_spec.rb new file mode 100644 index 00000000000..55bb43c6fcf --- /dev/null +++ b/spec/features/dashboard/root_spec.rb @@ -0,0 +1,19 @@ +# frozen_string_literal: true + +require 'spec_helper' + +RSpec.describe 'Root path' do + let_it_be(:user) { create(:user) } + let_it_be(:project) { create(:project) } + + before do + project.add_developer(user) + sign_in(user) + end + + it 'shows the customize banner', :js do + visit root_path + + expect(page).to have_content('Do you want to customize this page?') + end +end |