#138 fix tests for changed emoji path
This commit is contained in:
parent
d86973d0a5
commit
b19338ba5f
@ -33,7 +33,7 @@ module WikiFormatting
|
||||
</code></pre>
|
||||
HTML
|
||||
expected = <<~HTML
|
||||
<img title="heavy black heart" class="inline_emojify" src="http://localhost:3000/images/emojis/emoji_u2764.png">
|
||||
<img title="heavy black heart" class="inline_emojify" src="http://localhost:3000/#{Additionals::EMOJI_ASSERT_PATH}/emoji_u2764.png">
|
||||
<pre><code>
|
||||
def foo
|
||||
:heart:
|
||||
|
@ -27,7 +27,7 @@ module WikiFormatting
|
||||
disable_emoji_native_support: 1 do
|
||||
text = 'A test with a :heart: emoji'
|
||||
assert_equal '<p>A test with a <img title="heavy black heart" class="inline_emojify"' \
|
||||
' src="http://localhost:3000/images/emojis/emoji_u2764.png" /> emoji</p>',
|
||||
" src=\"http://localhost:3000/#{Additionals::EMOJI_ASSERT_PATH}/emoji_u2764.png\" /> emoji</p>",
|
||||
@formatter.new(text).to_html.strip
|
||||
end
|
||||
end
|
||||
@ -38,14 +38,14 @@ module WikiFormatting
|
||||
disable_emoji_native_support: 1 do
|
||||
text = ':heart: and :)'
|
||||
assert_equal '<p><img title="heavy black heart" class="inline_emojify"' \
|
||||
' src="http://localhost:3000/images/emojis/emoji_u2764.png" />' \
|
||||
" src=\"http://localhost:3000/#{Additionals::EMOJI_ASSERT_PATH}/emoji_u2764.png\" />" \
|
||||
' and <span class="additionals smiley smiley-smiley" title=":)"></span></p>',
|
||||
@formatter.new(text).to_html.strip
|
||||
|
||||
text = ' :) and :heart:'
|
||||
assert_equal '<p><span class="additionals smiley smiley-smiley" title=":)"></span> and' \
|
||||
' <img title="heavy black heart" class="inline_emojify"' \
|
||||
' src="http://localhost:3000/images/emojis/emoji_u2764.png" /></p>',
|
||||
" src=\"http://localhost:3000/#{Additionals::EMOJI_ASSERT_PATH}/emoji_u2764.png\" /></p>",
|
||||
@formatter.new(text).to_html.strip
|
||||
end
|
||||
end
|
||||
|
@ -34,7 +34,7 @@ module WikiFormatting
|
||||
|
||||
str = 'A test with a :heart: emoji and a :) smiley'
|
||||
@to_test[str] = 'A test with a <img title="heavy black heart" class="inline_emojify"' \
|
||||
' src="http://localhost:3000/images/emojis/emoji_u2764.png" /> emoji and a :) smiley'
|
||||
" src=\"http://localhost:3000/#{Additionals::EMOJI_ASSERT_PATH}/emoji_u2764.png\" /> emoji and a :) smiley"
|
||||
assert_html_output @to_test
|
||||
end
|
||||
end
|
||||
@ -47,11 +47,11 @@ module WikiFormatting
|
||||
@formatter::RULES << :inline_smileys
|
||||
|
||||
@to_test[':heart: and :)'] = '<img title="heavy black heart" class="inline_emojify"' \
|
||||
' src="http://localhost:3000/images/emojis/emoji_u2764.png" />' \
|
||||
" src=\"http://localhost:3000/#{Additionals::EMOJI_ASSERT_PATH}/emoji_u2764.png\" />" \
|
||||
' and <span class="additionals smiley smiley-smiley" title=":)"></span>'
|
||||
@to_test[':) and :heart:'] = '<span class="additionals smiley smiley-smiley" title=":)"></span> and' \
|
||||
' <img title="heavy black heart" class="inline_emojify"' \
|
||||
' src="http://localhost:3000/images/emojis/emoji_u2764.png" />'
|
||||
" src=\"http://localhost:3000/#{Additionals::EMOJI_ASSERT_PATH}/emoji_u2764.png\" />"
|
||||
assert_html_output @to_test
|
||||
end
|
||||
end
|
||||
|
Loading…
Reference in New Issue
Block a user