### Question:
Kelly { public void expire(String key) throws KellyException { T value = get(key); CacheEntry<T> cacheEntry = new CacheEntry<T>(key,value,-10); put(key,cacheEntry); get(key); } @Deprecated  Kelly(CacheProvider<T> cacheProvider, CacheLoader<T> cacheLoader, int executorPoolSize);  Kelly(CacheProvider<T> cacheProvider, CacheLoader<T> cacheLoader, int threadPoolSize,
                 int queueSize); T get(String key); boolean put(String key, CacheEntry<T> value); void expire(String key);  }### Answer:
@Test(dependsOnMethods = {"requestsInFlightTest"}) public void expireTest() throws KellyException, CacheProviderException, InterruptedException { CacheEntry<String> cacheEntry = new CacheEntry<String>("dude","suman",300); CacheProvider<String> cacheProvider = new DummyCacheProvider(); CacheLoader<String> cacheLoader = new DummyCacheLoader(); Kelly<String> kelly = new Kelly<String>(cacheProvider,cacheLoader,10); kelly.put("dude",cacheEntry); kelly.expire("dude"); assert cacheProvider.get("dude").getTtl()==-10; Thread.sleep(4000); assert kelly.get("dude").equals("suman karthik"); }