[ruby/rdoc] Process crossref before tidylink

The crossref must be linked before tidylink because Klass.method[:sym] will be
processed as a tidylink first and will be broken.

0f47baf6d2
This commit is contained in:
aycabta 2020-04-14 19:33:45 +09:00
parent c79f9ea606
commit f52a4690f8
3 changed files with 36 additions and 8 deletions

View file

@ -151,6 +151,13 @@ class TestRDocMarkupToHtmlCrossref < XrefTestCase
REGEXP_HANDLING('#m')
end
def test_handle_regexp_CROSSREF_with_arg_looks_like_TIDYLINK
result = @to.convert 'C1.m[:sym]'
assert_equal para("<a href=\"C1.html#method-c-m\"><code>C1.m[:sym]</code></a>"), result,
'C1.m[:sym]'
end
def test_handle_regexp_HYPERLINK_rdoc
readme = @store.add_file 'README.txt'
readme.parser = RDoc::Parser::Simple