@Test
  public void testVerifyCacheXml() throws Exception {
    createCacheXML();
    ds.disconnect();
    // Connect to the GemFire distributed system
    Properties props = new Properties();
    props.setProperty(NAME, getClass().getSimpleName());
    props.setProperty(MCAST_PORT, "0");
    String path = getClass().getSimpleName() + ".xml";
    props.setProperty(CACHE_XML_FILE, path);
    ds = DistributedSystem.connect(props);
    // Create the cache which causes the cache-xml-file to be parsed
    cache = CacheFactory.create(ds);

    // Get the regions[0]
    verify((LocalRegion) cache.getRegion("regions1"), diskRegionProperties[0]);

    // Get the regions[1]
    verify((LocalRegion) cache.getRegion("regions2"), diskRegionProperties[1]);

    // Get the regions[2]
    verify((LocalRegion) cache.getRegion("regions3"), diskRegionProperties[2]);

    // Get the regions[3]
    verify((LocalRegion) cache.getRegion("regions4"), diskRegionProperties[3]);

    // Get the regions[4]
    verify((LocalRegion) cache.getRegion("regions5"), diskRegionProperties[4]);

    // Get the regions[5]
    verify((LocalRegion) cache.getRegion("regions6"), diskRegionProperties[5]);

    // Get the regions[6]
    verify((LocalRegion) cache.getRegion("regions7"), diskRegionProperties[6]);

    // Get the regions[7]
    verify((LocalRegion) cache.getRegion("regions8"), diskRegionProperties[7]);

    // Get the regions[8]
    verify((LocalRegion) cache.getRegion("regions9"), diskRegionProperties[8]);

    // Get the regions[9]
    verify((LocalRegion) cache.getRegion("regions10"), diskRegionProperties[9]);

    // Get the regions[10]
    verify((LocalRegion) cache.getRegion("regions11"), diskRegionProperties[10]);

    // Get the regions[11]
    verify((LocalRegion) cache.getRegion("regions12"), diskRegionProperties[11]);
  }
This test is for testing Disk attributes set programmatically The generated cacheXml is used to
create a cache and the region properties retested.
geode-core/src/integrationTest/java/org/apache/geode/internal/cache/DiskRegCachexmlGeneratorJUnitTest.java