@Test
 public void infinispanCacheWithConfig() {
   load(
       DefaultCacheConfiguration.class,
       "spring.cache.type=infinispan",
       "spring.cache.infinispan.config=infinispan.xml");
   SpringEmbeddedCacheManager cacheManager =
       validateCacheManager(SpringEmbeddedCacheManager.class);
   assertThat(cacheManager.getCacheNames(), containsInAnyOrder("foo", "bar"));
 }
  @Test
  public void infinispanCacheWithCachesAndCustomConfig() {
    load(
        InfinispanCustomConfiguration.class,
        "spring.cache.type=infinispan",
        "spring.cache.cacheNames[0]=foo",
        "spring.cache.cacheNames[1]=bar");
    SpringEmbeddedCacheManager cacheManager =
        validateCacheManager(SpringEmbeddedCacheManager.class);
    assertThat(cacheManager.getCacheNames(), containsInAnyOrder("foo", "bar"));
    assertThat(cacheManager.getCacheNames(), hasSize(2));

    ConfigurationBuilder defaultConfigurationBuilder =
        this.context.getBean(ConfigurationBuilder.class);
    verify(defaultConfigurationBuilder, times(2)).build();
  }