##// END OF EJS Templates
Fixed bold syntax around single character in series (#2351)....
Jean-Philippe Lang -
r2189:a140c9bd7480
parent child
Show More
@@ -382,14 +382,14 class RedCloth3 < String
382 (#{rcq})
382 (#{rcq})
383 (#{C})
383 (#{C})
384 (?::(\S+?))?
384 (?::(\S+?))?
385 ([^\s\-].*?[^\s\-]|\w)
385 (\w|[^\s\-].*?[^\s\-])
386 #{rcq}
386 #{rcq}
387 (?=[[:punct:]]|\s|\)|$)/x
387 (?=[[:punct:]]|\s|\)|$)/x
388 else
388 else
389 /(#{rcq})
389 /(#{rcq})
390 (#{C})
390 (#{C})
391 (?::(\S+))?
391 (?::(\S+))?
392 ([^\s\-].*?[^\s\-]|\w)
392 (\w|[^\s\-].*?[^\s\-])
393 #{rcq}/xm
393 #{rcq}/xm
394 end
394 end
395 [rc, ht, re, rtype]
395 [rc, ht, re, rtype]
@@ -251,7 +251,10 EXPECTED
251
251
252 def test_text_formatting
252 def test_text_formatting
253 to_test = {'*_+bold, italic and underline+_*' => '<strong><em><ins>bold, italic and underline</ins></em></strong>',
253 to_test = {'*_+bold, italic and underline+_*' => '<strong><em><ins>bold, italic and underline</ins></em></strong>',
254 '(_text within parentheses_)' => '(<em>text within parentheses</em>)'
254 '(_text within parentheses_)' => '(<em>text within parentheses</em>)',
255 'a *Humane Web* Text Generator' => 'a <strong>Humane Web</strong> Text Generator',
256 'a H *umane* W *eb* T *ext* G *enerator*' => 'a H <strong>umane</strong> W <strong>eb</strong> T <strong>ext</strong> G <strong>enerator</strong>',
257 'a *H* umane *W* eb *T* ext *G* enerator' => 'a <strong>H</strong> umane <strong>W</strong> eb <strong>T</strong> ext <strong>G</strong> enerator',
255 }
258 }
256 to_test.each { |text, result| assert_equal "<p>#{result}</p>", textilizable(text) }
259 to_test.each { |text, result| assert_equal "<p>#{result}</p>", textilizable(text) }
257 end
260 end
General Comments 0
You need to be logged in to leave comments. Login now