@Test
    public void testHeaderAndFooterNotExtraction() throws Exception {
        ParseContext context = new ParseContext();
        context.set(Locale.class, Locale.UK);

        OfficeParserConfig officeParserConfig = new OfficeParserConfig();
        officeParserConfig.setIncludeHeadersAndFooters(false);
        context.set(OfficeParserConfig.class, officeParserConfig);

        XMLResult xmlResult = getXML("testEXCEL_headers_footers.xls", context);
        assertEquals("application/vnd.ms-excel", xmlResult.metadata.get(Metadata.CONTENT_TYPE));
        String content = xmlResult.xml;
        assertContains("John Smith1", content);
        assertContains("John Smith50", content);
        assertContains("1 Corporate HQ", content);
        assertNotContained("Header - Corporate Spreadsheet", content);
        assertNotContained("Header - For Internal Use Only", content);
        assertNotContained("Header - Author: John Smith", content);
        assertNotContained("Footer - Corporate Spreadsheet", content);
        assertNotContained("Footer - For Internal Use Only", content);
        assertNotContained("Footer - Author: John Smith", content);

        //now test configuration via tika-config
        Parser configuredParser = null;
        try (InputStream is = getResourceAsStream("tika-config-headers-footers.xml")) {
            configuredParser = new AutoDetectParser(new TikaConfig(is));
        }
        content = getXML("testEXCEL_headers_footers.xls", configuredParser).xml;
        assertContains("John Smith1", content);
        assertContains("John Smith50", content);
        assertContains("1 Corporate HQ", content);
        assertNotContained("Header - Corporate Spreadsheet", content);
        assertNotContained("Header - For Internal Use Only", content);
        assertNotContained("Header - Author: John Smith", content);
        assertNotContained("Footer - Corporate Spreadsheet", content);
        assertNotContained("Footer - For Internal Use Only", content);
        assertNotContained("Footer - Author: John Smith", content);
    }
Ensures that custom OLE2 (HPSF) properties are extracted
tika-parsers/tika-parsers-standard/tika-parsers-standard-modules/tika-parser-microsoft-module/src/test/java/org/apache/tika/parser/microsoft/ExcelParserTest.java