diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2021-06-16 18:25:58 +0000 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2021-06-16 18:25:58 +0000 |
commit | a5f4bba440d7f9ea47046a0a561d49adf0a1e6d4 (patch) | |
tree | fb69158581673816a8cd895f9d352dcb3c678b1e /spec/features/projects/blobs | |
parent | d16b2e8639e99961de6ddc93909f3bb5c1445ba1 (diff) | |
download | gitlab-ce-a5f4bba440d7f9ea47046a0a561d49adf0a1e6d4.tar.gz |
Add latest changes from gitlab-org/gitlab@14-0-stable-eev14.0.0-rc42
Diffstat (limited to 'spec/features/projects/blobs')
-rw-r--r-- | spec/features/projects/blobs/blob_show_spec.rb | 22 |
1 files changed, 20 insertions, 2 deletions
diff --git a/spec/features/projects/blobs/blob_show_spec.rb b/spec/features/projects/blobs/blob_show_spec.rb index 3598aa2f423..595304789a6 100644 --- a/spec/features/projects/blobs/blob_show_spec.rb +++ b/spec/features/projects/blobs/blob_show_spec.rb @@ -172,7 +172,7 @@ RSpec.describe 'File blob', :js do end end - context 'sucessfully change ref of similar name' do + context 'successfully change ref of similar name' do before do project.repository.create_branch('dev') project.repository.create_branch('development') @@ -182,14 +182,32 @@ RSpec.describe 'File blob', :js do visit_blob('files/js/application.js', ref: 'development') switch_ref_to('dev') - expect(page.find('.file-title-name').text).to eq('application.js') + aggregate_failures do + expect(page.find('.file-title-name').text).to eq('application.js') + expect(page).not_to have_css('flash-container') + end end it 'switch ref from shorter to longer ref name' do visit_blob('files/js/application.js', ref: 'dev') switch_ref_to('development') + aggregate_failures do + expect(page.find('.file-title-name').text).to eq('application.js') + expect(page).not_to have_css('flash-container') + end + end + end + + it 'successfully changes ref when the ref name matches the project name' do + project.repository.create_branch(project.name) + + visit_blob('files/js/application.js', ref: project.name) + switch_ref_to('master') + + aggregate_failures do expect(page.find('.file-title-name').text).to eq('application.js') + expect(page).not_to have_css('flash-container') end end end |