@Test
public void testHtml5Charset() throws Exception {

    String test =
            "<html><head><meta charset=\"ISO-8859-15\" />"
                    + "<title>the name is \u00e1ndre</title>"
                    + "</head><body></body></html>";
    Metadata metadata = new Metadata();
    new HtmlParser().parse(
            new ByteArrayInputStream(test.getBytes(ISO_8859_1)),
            new BodyContentHandler(), metadata, new ParseContext());
    assertEquals("ISO-8859-15", metadata.get(Metadata.CONTENT_ENCODING));
}