Commit 754bb5d8 authored by Heinrich Lee Yu's avatar Heinrich Lee Yu

Merge branch 'fix-fork-link-display-bug' into 'master'

Fix a display bug in the fork removal description message

Closes #37446

See merge request gitlab-org/gitlab!20843
parents b1b0acf8 3514a0bf
......@@ -114,8 +114,10 @@ module ProjectsHelper
source = visible_fork_source(project)
if source
_('This will remove the fork relationship between this project and %{fork_source}.') %
msg = _('This will remove the fork relationship between this project and %{fork_source}.') %
{ fork_source: link_to(source.full_name, project_path(source)) }
msg.html_safe
else
_('This will remove the fork relationship between this project and other projects in the fork network.')
end
......
---
title: Fix a display bug in the fork removal description message
merge_request: 20843
author:
type: fixed
......@@ -53,6 +53,7 @@ describe 'projects/edit' do
render
expect(rendered).to have_content('Remove fork relationship')
expect(rendered).to have_link(source_project.full_name, href: project_path(source_project))
end
it 'hides the fork relationship settings from an unauthorized user' do
......@@ -78,7 +79,7 @@ describe 'projects/edit' do
render
expect(rendered).to have_content('Remove fork relationship')
expect(rendered).to have_content(source_project.full_name)
expect(rendered).to have_link(source_project.full_name, href: project_path(source_project))
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