summaryrefslogtreecommitdiffstats
path: root/test/unit/lib
diff options
context:
space:
mode:
authorJean-Philippe Lang <jp_lang@yahoo.fr>2014-11-14 20:18:09 +0000
committerJean-Philippe Lang <jp_lang@yahoo.fr>2014-11-14 20:18:09 +0000
commitc12ba8a76cfa54b2f980017a1ca4a5d28bf8ce5d (patch)
treef3e15f07feec5aec1f8e8f5830070cafbe8223b8 /test/unit/lib
parent429e266bef42b9cdae23ccfe2375f1cf42865fc1 (diff)
downloadredmine-c12ba8a76cfa54b2f980017a1ca4a5d28bf8ce5d.tar.gz
redmine-c12ba8a76cfa54b2f980017a1ca4a5d28bf8ce5d.zip
Fixed that URLs separated by line break are not rendered as links (#18349).
git-svn-id: http://svn.redmine.org/redmine/trunk@13592 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'test/unit/lib')
-rw-r--r--test/unit/lib/redmine/wiki_formatting_test.rb13
1 files changed, 13 insertions, 0 deletions
diff --git a/test/unit/lib/redmine/wiki_formatting_test.rb b/test/unit/lib/redmine/wiki_formatting_test.rb
index 830ab20ca..05c0f5e1d 100644
--- a/test/unit/lib/redmine/wiki_formatting_test.rb
+++ b/test/unit/lib/redmine/wiki_formatting_test.rb
@@ -48,6 +48,19 @@ EXPECTED
assert_equal expected.gsub(%r{[\r\n\t]}, ''), Redmine::WikiFormatting::NullFormatter::Formatter.new(raw).to_html.gsub(%r{[\r\n\t]}, '')
end
+ def test_links_separated_with_line_break_should_link
+ raw = <<-DIFF
+link: https://www.redmine.org
+http://www.redmine.org
+DIFF
+
+ expected = <<-EXPECTED
+<p>link: <a class="external" href="https://www.redmine.org">https://www.redmine.org</a><br />
+<a class="external" href="http://www.redmine.org">http://www.redmine.org</a></p>
+EXPECTED
+
+ end
+
def test_supports_section_edit
with_settings :text_formatting => 'textile' do
assert_equal true, Redmine::WikiFormatting.supports_section_edit?