summaryrefslogtreecommitdiff
path: root/spec
diff options
context:
space:
mode:
authorStan Hu <stanhu@gmail.com>2015-10-01 14:10:34 -0700
committerStan Hu <stanhu@gmail.com>2015-10-01 14:10:34 -0700
commit1c53c28c795f70536da74fecf0cd7abfaeacd2a5 (patch)
tree02e3de8beeda5a79ac73f778b632dbc07b43a875 /spec
parent3fa8bd0e67233cb3636490fb35993e2db3424772 (diff)
parenta3c6ed5c4650a7c8643e57929a34a219c6a15a8a (diff)
downloadgitlab-ce-1c53c28c795f70536da74fecf0cd7abfaeacd2a5.tar.gz
Merge pull request #9684 from NKMR6194/master
Fix link with emoji
Diffstat (limited to 'spec')
-rw-r--r--spec/helpers/gitlab_markdown_helper_spec.rb6
1 files changed, 6 insertions, 0 deletions
diff --git a/spec/helpers/gitlab_markdown_helper_spec.rb b/spec/helpers/gitlab_markdown_helper_spec.rb
index be0e0c747b7..20ae29e2bd3 100644
--- a/spec/helpers/gitlab_markdown_helper_spec.rb
+++ b/spec/helpers/gitlab_markdown_helper_spec.rb
@@ -106,6 +106,12 @@ describe GitlabMarkdownHelper do
act = link_to_gfm(text, '/foo')
expect(act).to eq %Q(<a href="/foo">#{issues[0].to_reference}</a>)
end
+
+ it 'should replace commit message with emoji to link' do
+ actual = link_to_gfm(':book:Book', '/foo')
+ expect(actual).
+ to eq %Q(<img class="emoji" title=":book:" alt=":book:" src="http://localhost/assets/emoji/1F4D6.png" height="20" width="20" align="absmiddle"><a href="/foo">Book</a>)
+ end
end
describe '#render_wiki_content' do