Added extra spec to cover alleged bug case given in issue #2245 .

This commit is contained in:
Pistos 2011-11-02 09:23:05 -04:00
parent 3567423d98
commit 0bb65e8718

View file

@ -58,6 +58,14 @@ describe MarkdownifyHelper do
formatted = markdownify(message) formatted = markdownify(message)
formatted.should =~ /hovercard/ formatted.should =~ /hovercard/
end end
it 'should process text with both a hashtag and a link' do
message = Factory.create(:status_message,
:author => alice.person,
:text => "Test #tag?\nhttps://joindiaspora.com\n")
formatted = markdownify(message)
formatted.should == %{<p>Test <a href="/tags/tag" class="tag">#tag</a>?<br>\n<a href="https://joindiaspora.com" target="_blank">https://joindiaspora.com</a></p>\n}
end
end end
end end
end end