@Test
    public void testParseKeynote() throws Exception {
        Metadata metadata = new Metadata();
        String content = getText("testKeynote.key", iWorkParser, metadata);

        // Make sure enough keys came through
        // (Exact numbers will vary based on composites)
        assertTrue(metadata.size() >= 6, "Insufficient metadata found " + metadata.size());
        List<String> metadataKeys = Arrays.asList(metadata.names());
        assertTrue(metadataKeys.contains(Metadata.CONTENT_TYPE),
                "Metadata not found in " + metadataKeys);
        assertTrue(metadataKeys.contains(Office.SLIDE_COUNT.getName()),
                "Metadata not found in " + metadataKeys);
//        assertTrue("Metadata not found in " + metadataKeys,
//        metadataKeys.contains(Office.SLIDE_COUNT.getName()));
        assertTrue(metadataKeys.contains(TikaCoreProperties.CREATOR.getName()),
                "Metadata not found in " + metadataKeys);
        assertTrue(metadataKeys.contains(TikaCoreProperties.TITLE.getName()),
                "Metadata not found in " + metadataKeys);

        // Check the metadata values
        assertEquals("application/vnd.apple.keynote", metadata.get(Metadata.CONTENT_TYPE));
        assertEquals("3", metadata.get(Office.SLIDE_COUNT));
        assertEquals("1024", metadata.get(KeynoteContentHandler.PRESENTATION_WIDTH));
        assertEquals("768", metadata.get(KeynoteContentHandler.PRESENTATION_HEIGHT));
        assertEquals("Tika user", metadata.get(TikaCoreProperties.CREATOR));
        assertEquals("Apache tika", metadata.get(TikaCoreProperties.TITLE));

        assertContains("A sample presentation", content);
        assertContains("For the Apache Tika project", content);
        assertContains("Slide 1", content);
        assertContains("Some random text for the sake of testability.", content);
        assertContains("A nice comment", content);
        assertContains("A nice note", content);

        // test table data
        assertContains("Cell one", content);
        assertContains("Cell two", content);
        assertContains("Cell three", content);
        assertContains("Cell four", content);
        assertContains("Cell 5", content);
        assertContains("Cell six", content);
        assertContains("7", content);
        assertContains("Cell eight", content);
        assertContains("5/5/1985", content);
    }
Check the given InputStream is not closed by the Parser (TIKA-1117).

@throws Exception
tika-parsers/tika-parsers-standard/tika-parsers-standard-modules/tika-parser-apple-module/src/test/java/org/apache/tika/parser/iwork/IWorkParserTest.java