Package com.cetsoft.imcache.cache

Examples of com.cetsoft.imcache.cache.Cache


  @Test
  public void getCache(){
    doReturn(1).when(type).getType();
    doReturn(cacheMap).when(cacheCoordinator).getOrCreate();
    doReturn(cache).when(cacheMap).get(anyInt());
    Cache actualCache = cacheCoordinator.getCache(type);
    assertEquals(cache, actualCache);
  }
View Full Code Here


    doReturn(1).when(type).getType();
    doReturn(cacheMap).when(cacheCoordinator).getOrCreate();
    doReturn(null).when(cacheMap).get(anyInt());
    doReturn(cache).when(cacheFactory).create();
    doNothing().when(cacheCoordinator).addCache(type, cache);
    Cache actualCache = cacheCoordinator.getCache(type);
    verify(cacheCoordinator).addCache(type, cache);
    assertEquals(cache, actualCache);
  }
View Full Code Here

      }
    }).start();
    try {
      latch.await();
    } catch (InterruptedException e) {}
    Cache actualCache = cacheCoordinator.getCache(cacheType);
    assertEquals(cache, actualCache);
  }
View Full Code Here

TOP

Related Classes of com.cetsoft.imcache.cache.Cache

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.