Substitute right single quote back with apostrophe.
This commit is contained in:
parent
a912308340
commit
1d14676e0c
2 changed files with 3 additions and 2 deletions
|
@ -49,6 +49,7 @@ class Redcarpet::Render::GitlabHTML < Redcarpet::Render::HTML
|
||||||
end
|
end
|
||||||
|
|
||||||
def postprocess(full_document)
|
def postprocess(full_document)
|
||||||
|
full_document.gsub!("’", "'")
|
||||||
unless @template.instance_variable_get("@project_wiki") || @project.nil?
|
unless @template.instance_variable_get("@project_wiki") || @project.nil?
|
||||||
full_document = h.create_relative_links(full_document)
|
full_document = h.create_relative_links(full_document)
|
||||||
end
|
end
|
||||||
|
|
|
@ -535,7 +535,7 @@ describe GitlabMarkdownHelper do
|
||||||
project.issues.stub(:where).with(iid: '39').and_return([issue])
|
project.issues.stub(:where).with(iid: '39').and_return([issue])
|
||||||
|
|
||||||
actual = "Yes, it is @#{member.user.username}'s task."
|
actual = "Yes, it is @#{member.user.username}'s task."
|
||||||
expected = /Yes, it is <a.+>@#{member.user.username}<\/a>’s task/
|
expected = /Yes, it is <a.+>@#{member.user.username}<\/a>'s task/
|
||||||
markdown(actual).should match(expected)
|
markdown(actual).should match(expected)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
@ -574,7 +574,7 @@ describe GitlabMarkdownHelper do
|
||||||
|
|
||||||
it "should leave inline code untouched" do
|
it "should leave inline code untouched" do
|
||||||
markdown("\nDon't use `$#{snippet.id}` here.\n").should ==
|
markdown("\nDon't use `$#{snippet.id}` here.\n").should ==
|
||||||
"<p>Don’t use <code>$#{snippet.id}</code> here.</p>\n"
|
"<p>Don't use <code>$#{snippet.id}</code> here.</p>\n"
|
||||||
end
|
end
|
||||||
|
|
||||||
it "should leave ref-like autolinks untouched" do
|
it "should leave ref-like autolinks untouched" do
|
||||||
|
|
Loading…
Reference in a new issue