@Test
  public void createIndex() throws FileNotFoundException {
    CacheFactory cf = new CacheFactory();
    cf.set(MCAST_PORT, "0");
    cf.set(CACHE_XML_FILE, getXmlFileForTest());
    Cache cache = cf.create();

    try {
      LuceneService service = LuceneServiceProvider.get(cache);
      assertEquals(3, service.getAllIndexes().size());
      LuceneIndex index1 = service.getIndex("index1", SEPARATOR + "region");
      LuceneIndex index2 = service.getIndex("index2", SEPARATOR + "region");
      LuceneIndex index3 = service.getIndex("index3", SEPARATOR + "region");
      assertArrayEquals(index1.getFieldNames(), new String[] {"a", "b", "c", "d"});
      assertArrayEquals(index2.getFieldNames(), new String[] {"f", "g"});
      assertArrayEquals(index3.getFieldNames(), new String[] {"h", "i", "j"});
    } finally {
      tearDownCacheAfterCreateIndexTestIsCompleted(cache);
    }
  }
Test that the Index creation objects get appropriately translated into a real index.
geode-lucene/src/integrationTest/java/org/apache/geode/cache/lucene/internal/xml/LuceneIndexXmlParserIntegrationJUnitTest.java