@Test
    public void testXMLReaderUtilsNoPool() throws Exception {
        //pool size may have been reset already by an
        //earlier test.  Can't test for default here.
        assertEquals(XMLReaderUtils.DEFAULT_MAX_ENTITY_EXPANSIONS,
                XMLReaderUtils.getMaxEntityExpansions());
        //make sure that detection on this file actually works with
        //default expansions
        assertEquals("application/rdf+xml",
                detect("test-difficult-rdf1.xml", TikaConfig.getDefaultConfig()).toString());

        TikaConfig tikaConfig = getConfig("TIKA-4427-no-sax-pool.xml");
        try {
            assertEquals(0, XMLReaderUtils.getPoolSize());
            assertEquals(5, XMLReaderUtils.getMaxEntityExpansions());
            //make sure that there's actually a change in behavior
            assertEquals("text/plain", detect("test-difficult-rdf1.xml", tikaConfig).toString());
        } finally {
            XMLReaderUtils.setMaxEntityExpansions(XMLReaderUtils.DEFAULT_MAX_ENTITY_EXPANSIONS);
            XMLReaderUtils.setPoolSize(XMLReaderUtils.DEFAULT_POOL_SIZE);
        }
    }
TIKA-1653 If one parser has child parsers, those child parsers shouldn't
show up at the top level as well
tika-core/src/test/java/org/apache/tika/config/TikaConfigTest.java