Adds support for converting <-> to ↔ in markdownify

This commit is contained in:
Robin Wellner 2011-06-30 14:27:39 +02:00
parent 3a5f0c9678
commit 91dd4f847a
2 changed files with 3 additions and 2 deletions

View file

@ -118,6 +118,7 @@ module MarkdownifyHelper
":-(" => "&#9785;",
":)" => "&#9786;",
":-)" => "&#9786;",
"&lt;-&gt;" => "&#8596;",
"-&gt;" => "&rarr;",
"&lt;-" => "&larr;",
"..." => "&hellip;",

View file

@ -157,8 +157,8 @@ describe MarkdownifyHelper do
end
it "replaces various things with (their) HTML entities" do
message = ":) :-) :( :-( ... -> <- (tm) (r) (c)"
markdownify(message).should == "&#9786; &#9786; &#9785; &#9785; &hellip; &rarr; &larr; &trade; &reg; &copy;"
message = ":) :-) :( :-( ... <-> -> <- (tm) (r) (c)"
markdownify(message).should == "&#9786; &#9786; &#9785; &#9785; &hellip; &#8596; &rarr; &larr; &trade; &reg; &copy;"
end
it "skips doing it if you say so" do