public void StaticCacheHandler_GetValueWithArea_NoExistingItems() { ICacheService handler = new LocalCacheService(); object value = handler.GetCacheValue("LocalCacheService_GetValueWithRegion_NoExistingItems", "area1"); Assert.Null(value); }
public void StaticCacheHandler_Get_None() { ICacheService handler = new LocalCacheService(); object value = handler.GetCacheValue("key", "area"); Assert.Null(value); }
public void StaticCacheHandler_GetWithDifferentType_Found() { ICacheService handler = new LocalCacheService(); handler.PutCacheValue("key", "val1", "area"); AuthorityReport site = handler.GetCacheValue <AuthorityReport>("key", "area"); Assert.Null(site); }
public void StaticCacheHandler_GetWithType_Found() { ICacheService handler = new LocalCacheService(); handler.PutCacheValue("key", "val1", "area"); string value = handler.GetCacheValue <string>("key", "area"); Assert.Equal("val1", value); }
public void StaticCacheHandler_Get_Found() { ICacheService handler = new LocalCacheService(); handler.PutCacheValue("key", "val1", "area"); object value = handler.GetCacheValue("key", "area"); Assert.Equal("val1", value); }
public void StaticCacheHandler_RetrieveStoredItem() { ICacheService handler = new LocalCacheService(); handler.PutCacheValue("LocalCacheService_RetrieveStoredItem", "value1", "area1"); object value = handler.GetCacheValue("LocalCacheService_RetrieveStoredItem", "area1"); Assert.NotNull(value); Assert.Equal("value1", value); }
public void StaticCacheHandler_RemoveCacheValue() { ICacheService handler = new LocalCacheService(); handler.PutCacheValue("key", "val1", "area"); handler.RemoveCacheValue("key", "area"); object value = handler.GetCacheValue("key", "area"); Assert.Null(value); }