@Test public void testCacheConfig() { assertNotNull(config); assertEquals(1, config.getCacheConfigs().size()); CacheSimpleConfig cacheConfig = config.getCacheConfig("testCache"); assertEquals("testCache", cacheConfig.getName()); WanReplicationRef wanRef = cacheConfig.getWanReplicationRef(); assertEquals("testWan", wanRef.getName()); assertEquals("PUT_IF_ABSENT", wanRef.getMergePolicy()); assertFalse(wanRef.isRepublishingEnabled()); }
@Test public void testCacheConfig() { assertNotNull(config); assertEquals(1, config.getCacheConfigs().size()); CacheSimpleConfig cacheConfig = config.getCacheConfig("testCache"); assertEquals("testCache", cacheConfig.getName()); assertTrue(cacheConfig.getHotRestartConfig().isEnabled()); assertTrue(cacheConfig.getHotRestartConfig().isFsync()); WanReplicationRef wanRef = cacheConfig.getWanReplicationRef(); assertEquals("testWan", wanRef.getName()); assertEquals("PUT_IF_ABSENT", wanRef.getMergePolicy()); assertEquals(1, wanRef.getFilters().size()); assertEquals("com.example.SampleFilter", wanRef.getFilters().get(0)); assertFalse(wanRef.isRepublishingEnabled()); }