File tree Expand file tree Collapse file tree 3 files changed +10
-1
lines changed Expand file tree Collapse file tree 3 files changed +10
-1
lines changed Original file line number Diff line number Diff line change 33* Bug fixes
44 * Fix RDoc::Markup parser for a header followed by a non-text token. Issue
55 #56 by Adam Tait
6+ * Fix RDoc::Markup::ToHtmlCrossref#gen_url for non-<tt>rdoc-ref</tt> links.
67 * Fix bug report URL when rdoc crashes.
78
89=== 3.9 / 2011-07-30
Original file line number Diff line number Diff line change @@ -97,7 +97,7 @@ def handle_special_HYPERLINK special
9797 # RDoc::Markup::ToHtml to handle other schemes.
9898
9999 def gen_url url , text
100- super unless url =~ /\A rdoc-ref:/
100+ return super unless url =~ /\A rdoc-ref:/
101101
102102 cross_reference $', text
103103 end
Original file line number Diff line number Diff line change @@ -25,6 +25,14 @@ def test_convert_HYPERLINK_rdoc_ref
2525 assert_equal "\n <p><a href=\" C1.html\" >C1</a></p>\n " , result
2626 end
2727
28+ def test_gen_url
29+ assert_equal '<a href="C1.html">Some class</a>' ,
30+ @to . gen_url ( 'rdoc-ref:C1' , 'Some class' )
31+
32+ assert_equal '<a href="http://example">HTTP example</a>' ,
33+ @to . gen_url ( 'http://example' , 'HTTP example' )
34+ end
35+
2836 def test_handle_special_CROSSREF
2937 assert_equal "<a href=\" C2/C3.html\" >C2::C3</a>" , SPECIAL ( 'C2::C3' )
3038 end
You can’t perform that action at this time.
0 commit comments