@Test
  public void testCallbackWithException() throws Exception {
    setXmlFile(findFile("callbackWithException.xml"));

    IgnoredException expectedException =
        addIgnoredException("While reading Cache XML file");
    try {
      getCache();
      fail("Should have thrown a CacheXmlException");

    } catch (CacheXmlException ex) {
      if (!(ex.getCause() instanceof AssertionError)) {
        throw ex;
      }
    } finally {
      expectedException.remove();
    }

  }
Tests parsing an XML file that specifies a cache listener whose constructor throws an
{@linkplain AssertionError exception}.
geode-core/src/distributedTest/java/org/apache/geode/cache30/CacheXml66DUnitTest.java