Commit 4ff3ef6f authored by ubudzisz's avatar ubudzisz

add modification to commit title test

add modification to commit title test

add empty line
parent af44c0ba
...@@ -4,7 +4,10 @@ describe 'projects/builds/show' do ...@@ -4,7 +4,10 @@ describe 'projects/builds/show' do
include Devise::TestHelpers include Devise::TestHelpers
let(:project) { create(:project) } let(:project) { create(:project) }
let(:pipeline) { create(:ci_pipeline, project: project) } let(:pipeline) do
create(:ci_pipeline, project: project,
sha: project.commit.id)
end
let(:build) { create(:ci_build, pipeline: pipeline) } let(:build) { create(:ci_build, pipeline: pipeline) }
before do before do
...@@ -36,13 +39,14 @@ describe 'projects/builds/show' do ...@@ -36,13 +39,14 @@ describe 'projects/builds/show' do
end end
end end
describe 'projects/builds/show/commit title' do describe 'commit title in sidebar' do
let(:commit_title) {build.project.commit.title} let(:commit_title) { project.commit.title }
it 'shows commit title' do it 'shows commit title and not show commit message' do
within('p.build-light-text.append-bottom-0') do render
expect(rendered).to have_content(commit_title)
end expect(rendered).to have_css('p.build-light-text.append-bottom-0',
text: /\A\n#{Regexp.escape(commit_title)}\n\Z/)
end end
end end
end end
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment