diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2021-06-17 10:07:47 +0000 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2021-06-17 10:07:47 +0000 |
commit | d670c3006e6e44901bce0d53cc4768d1d80ffa92 (patch) | |
tree | 8f65743c232e5b76850c4cc264ba15e1185815ff /spec/features | |
parent | a5f4bba440d7f9ea47046a0a561d49adf0a1e6d4 (diff) | |
download | gitlab-ce-d670c3006e6e44901bce0d53cc4768d1d80ffa92.tar.gz |
Add latest changes from gitlab-org/gitlab@14-0-stable-ee
Diffstat (limited to 'spec/features')
-rw-r--r-- | spec/features/admin/admin_users_spec.rb | 6 | ||||
-rw-r--r-- | spec/features/merge_request/user_sees_merge_request_pipelines_spec.rb | 2 | ||||
-rw-r--r-- | spec/features/projects/active_tabs_spec.rb | 51 | ||||
-rw-r--r-- | spec/features/users/login_spec.rb | 14 |
4 files changed, 68 insertions, 5 deletions
diff --git a/spec/features/admin/admin_users_spec.rb b/spec/features/admin/admin_users_spec.rb index 6d5944002a1..2b627707ff2 100644 --- a/spec/features/admin/admin_users_spec.rb +++ b/spec/features/admin/admin_users_spec.rb @@ -15,7 +15,7 @@ RSpec.describe "Admin::Users" do let(:active_tab_selector) { '.nav-link.active' } it 'links to the Users tab' do - visit cohorts_admin_users_path + visit admin_cohorts_path within tabs_selector do click_link 'Users' @@ -35,14 +35,14 @@ RSpec.describe "Admin::Users" do expect(page).to have_selector active_tab_selector, text: 'Cohorts' end - expect(page).to have_current_path(cohorts_admin_users_path) + expect(page).to have_current_path(admin_cohorts_path) expect(page).to have_selector active_tab_selector, text: 'Cohorts' end it 'redirects legacy route' do visit admin_users_path(tab: 'cohorts') - expect(page).to have_current_path(cohorts_admin_users_path) + expect(page).to have_current_path(admin_cohorts_path) end end diff --git a/spec/features/merge_request/user_sees_merge_request_pipelines_spec.rb b/spec/features/merge_request/user_sees_merge_request_pipelines_spec.rb index d555519eb43..85eb956033b 100644 --- a/spec/features/merge_request/user_sees_merge_request_pipelines_spec.rb +++ b/spec/features/merge_request/user_sees_merge_request_pipelines_spec.rb @@ -25,8 +25,6 @@ RSpec.describe 'Merge request > User sees pipelines triggered by merge request', } end - let_it_be(:runner) { create(:ci_runner, :online) } - before do stub_application_setting(auto_devops_enabled: false) stub_ci_pipeline_yaml_file(YAML.dump(config)) diff --git a/spec/features/projects/active_tabs_spec.rb b/spec/features/projects/active_tabs_spec.rb index b333f64aa87..39950adc83f 100644 --- a/spec/features/projects/active_tabs_spec.rb +++ b/spec/features/projects/active_tabs_spec.rb @@ -182,4 +182,55 @@ RSpec.describe 'Project active tab' do it_behaves_like 'page has active sub tab', _('CI/CD') end end + + context 'on project CI/CD' do + context 'browsing Pipelines tabs' do + let_it_be(:pipeline) { create(:ci_pipeline, project: project) } + + context 'Pipeline tab' do + before do + visit project_pipeline_path(project, pipeline) + end + + it_behaves_like 'page has active tab', _('CI/CD') + it_behaves_like 'page has active sub tab', _('Pipelines') + end + + context 'Needs tab' do + before do + visit dag_project_pipeline_path(project, pipeline) + end + + it_behaves_like 'page has active tab', _('CI/CD') + it_behaves_like 'page has active sub tab', _('Pipelines') + end + + context 'Builds tab' do + before do + visit builds_project_pipeline_path(project, pipeline) + end + + it_behaves_like 'page has active tab', _('CI/CD') + it_behaves_like 'page has active sub tab', _('Pipelines') + end + + context 'Failures tab' do + before do + visit failures_project_pipeline_path(project, pipeline) + end + + it_behaves_like 'page has active tab', _('CI/CD') + it_behaves_like 'page has active sub tab', _('Pipelines') + end + + context 'Test Report tab' do + before do + visit test_report_project_pipeline_path(project, pipeline) + end + + it_behaves_like 'page has active tab', _('CI/CD') + it_behaves_like 'page has active sub tab', _('Pipelines') + end + end + end end diff --git a/spec/features/users/login_spec.rb b/spec/features/users/login_spec.rb index 1d7099ba443..7010059a7ff 100644 --- a/spec/features/users/login_spec.rb +++ b/spec/features/users/login_spec.rb @@ -128,6 +128,20 @@ RSpec.describe 'Login' do end end end + + context 'when resending the confirmation email' do + it 'redirects to the "almost there" page' do + stub_feature_flags(soft_email_confirmation: false) + + user = create(:user) + + visit new_user_confirmation_path + fill_in 'user_email', with: user.email + click_button 'Resend' + + expect(current_path).to eq users_almost_there_path + end + end end describe 'with the ghost user' do |