summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--spec/helpers/gitlab_markdown_helper_spec.rb8
1 files changed, 8 insertions, 0 deletions
diff --git a/spec/helpers/gitlab_markdown_helper_spec.rb b/spec/helpers/gitlab_markdown_helper_spec.rb
index 55270a9c204..0784834924c 100644
--- a/spec/helpers/gitlab_markdown_helper_spec.rb
+++ b/spec/helpers/gitlab_markdown_helper_spec.rb
@@ -539,6 +539,14 @@ describe GitlabMarkdownHelper do
markdown(actual).should match(expected)
end
+ it "should not link the apostrophe to issue 39 in code blocks" do
+ project.team << [user, :master]
+ project.issues.stub(:where).with(iid: '39').and_return([issue])
+
+ actual = "Yes, `it is @#{member.user.username}'s task.`"
+ expected = /Yes, <code>it is @gfm\'s task.<\/code>/
+ markdown(actual).should match(expected)
+ end
it "should handle references in <em>" do
actual = "Apply _!#{merge_request.iid}_ ASAP"