jhy/jsoup — Issue #147: Unhandled Character Entities
Author: helsom
Created: 2011-12-01 13:10:59+00:00
State: open

The following character entities do not appear to be retained after a call to jsoup.clean():

&euro;&OElig;&oelig;&sbquo;&bdquo;&trade;&bull;&rarr;&rArr;&hArr;&diams;&asymp;

Test case:

@Test public void entities() {
String html = "

€Œœ‚„™•→⇒⇔♦≈

";
Whitelist whitelist = Whitelist.none();
whitelist
.addTags("p");
String html = Jsoup.clean(html, whitelist);
assertEquals("

€Œœ‚„™•→⇒⇔♦≈

", html);
}