diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2021-11-25 03:10:49 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2021-11-25 03:10:49 +0300 |
commit | 4f79a3041736aadda887ebec4178731eb8681cff (patch) | |
tree | 57b76f5fccfe112eedc64916ac2719b917616299 /spec/views/projects | |
parent | 1f3baf00bfdff196b43ade455d8268ce10ff13aa (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'spec/views/projects')
-rw-r--r-- | spec/views/projects/edit.html.haml_spec.rb | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/spec/views/projects/edit.html.haml_spec.rb b/spec/views/projects/edit.html.haml_spec.rb index 60f4c1664f7..8c96f286c79 100644 --- a/spec/views/projects/edit.html.haml_spec.rb +++ b/spec/views/projects/edit.html.haml_spec.rb @@ -92,6 +92,22 @@ RSpec.describe 'projects/edit' do end end + context 'squash template' do + it 'displays a placeholder if none is set' do + render + + expect(rendered).to have_field('project[squash_commit_template]', placeholder: '%{title}') + end + + it 'displays the user entered value' do + project.update!(squash_commit_template: '%{first_multiline_commit}') + + render + + expect(rendered).to have_field('project[squash_commit_template]', with: '%{first_multiline_commit}') + end + end + context 'forking' do before do assign(:project, project) |