提交 ef304611 编写于 作者: S Stan Hu

Fix commit SHA not showing in merge request compare dropdown

https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/17011
in GitLab 11.1 refactored the merge request diff comparison
functionality but omitted the commit SHA due to a change in
the API (truncated_commit_sha -> short_commit_sha).

Closes https://gitlab.com/gitlab-org/gitlab-ce/issues/55822
上级 4d875a2b
...@@ -129,7 +129,7 @@ export default { ...@@ -129,7 +129,7 @@ export default {
</strong> </strong>
</div> </div>
<div> <div>
<small class="commit-sha"> {{ version.truncated_commit_sha }} </small> <small class="commit-sha"> {{ version.short_commit_sha }} </small>
</div> </div>
<div> <div>
<small> <small>
......
---
title: Fix commit SHA not showing in merge request compare dropdown
merge_request: 24084
author:
type: fixed
...@@ -64,6 +64,17 @@ describe 'Merge request > User sees versions', :js do ...@@ -64,6 +64,17 @@ describe 'Merge request > User sees versions', :js do
end end
end end
it 'shows the commit SHAs for every version in the dropdown' do
page.within '.mr-version-dropdown' do
find('.btn-default').click
page.within('.dropdown-content') do
shas = merge_request.merge_request_diffs.map { |diff| Commit.truncate_sha(diff.head_commit_sha) }
shas.each { |sha| expect(page).to have_content(sha) }
end
end
end
it 'shows comments that were last relevant at that version' do it 'shows comments that were last relevant at that version' do
expect(page).to have_content '5 changed files' expect(page).to have_content '5 changed files'
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册