@@ -59,7 +59,7 @@ def test_convert_RDOCLINK_rdoc_ref
59
59
def test_convert_RDOCLINK_rdoc_ref_method
60
60
result = @to . convert 'rdoc-ref:C1#m'
61
61
62
- assert_equal para ( "<a href=\" C1.html#method-i-m\" >#m</a>" ) , result
62
+ assert_equal para ( "<a href=\" C1.html#method-i-m\" >C1 #m</a>" ) , result
63
63
end
64
64
65
65
def test_convert_RDOCLINK_rdoc_ref_method_label
@@ -75,13 +75,13 @@ def test_convert_RDOCLINK_rdoc_ref_method_percent
75
75
76
76
result = @to . convert 'rdoc-ref:C1#%'
77
77
78
- assert_equal para ( "<a href=\" C1.html#method-i-25\" >#%</a>" ) , result
78
+ assert_equal para ( "<a href=\" C1.html#method-i-25\" >C1 #%</a>" ) , result
79
79
80
80
m . singleton = true
81
81
82
82
result = @to . convert 'rdoc-ref:C1::%'
83
83
84
- assert_equal para ( "<a href=\" C1.html#method-c-25\" >::%</a>" ) , result
84
+ assert_equal para ( "<a href=\" C1.html#method-c-25\" >C1 ::%</a>" ) , result
85
85
end
86
86
87
87
def test_convert_RDOCLINK_rdoc_ref_method_percent_label
@@ -200,11 +200,16 @@ def test_to_html_CROSSREF_email_hyperlink_all
200
200
def test_link
201
201
assert_equal 'n' , @to . link ( 'n' , 'n' )
202
202
203
- assert_equal '<a href="C1.html#method-c-m">::m</a>' , @to . link ( 'm' , 'm' )
203
+ assert_equal '<a href="C1.html#method-c-m">m</a>' , @to . link ( 'm' , 'm' )
204
+ end
205
+
206
+ def test_link_for_method_traverse
207
+ @to = RDoc ::Markup ::ToHtmlCrossref . new @options , 'C2.html' , @c9
208
+ assert_equal '<a href="C9/A.html#method-i-foo">C9::B#foo</a>' , @to . link ( 'C9::B#foo' , 'C9::B#foo' )
204
209
end
205
210
206
211
def test_link_class_method_full
207
- assert_equal '<a href="Parent.html#method-c-m">Parent. m</a>' ,
212
+ assert_equal '<a href="Parent.html#method-c-m">Parent:: m</a>' ,
208
213
@to . link ( 'Parent::m' , 'Parent::m' )
209
214
end
210
215
0 commit comments