public void OkToRemoveNonExistingObject() { var cache = new MockCache(); var cache_span = new TimeSpan(0, 0, 2); var key = blob_uri.ToString(); cache.Remove(key); Assert.That(cache[key] == null); }
public void RemovedObjectIsGone() { var cache = new MockCache(); var cache_span = new TimeSpan(0, 0, 2); var key = blob_uri.ToString(); cache.Insert(key, view_contents, null, Cache.NoAbsoluteExpiration, cache_span, CacheItemPriority.Normal, null); cache.Remove(key); Assert.That(cache[key] == null); }