public FontMetrics parse() throws IOException
    {
        return parseFontMetric(false);
    }
@Test
    void testEndFontMetrics() throws IOException
    {
        AFMParser parser = new AFMParser(
                new FileInputStream("src/test/resources/afm/NoEndFontMetrics.afm"));
        try
        {
            parser.parse();
            fail("The AFMParser should have thrown an IOException because of a missing "
                    + AFMParser.END_FONT_METRICS);
        }
        catch (IOException e)
        {
            assertTrue(e.getMessage().contains("Unknown AFM key"));
        }
    }