示例#1
0
        public async Task TestFromStagingArea()
        {
            Task         putTask = _bufferedDiskCache.Put(_cacheKey, _encodedImage);
            EncodedImage image   = _stagingArea.Get(_cacheKey);

            Assert.AreSame(
                _closeableReference.GetUnderlyingReferenceTestOnly(),
                image.GetByteBufferRef().GetUnderlyingReferenceTestOnly());
            await putTask;
        }
示例#2
0
 public void TestDoesntContainInvalid()
 {
     _encodedImage.Dispose();
     Assert.IsTrue(_stagingArea.ContainsKey(_cacheKey));
     Assert.IsTrue(EncodedImage.IsValid(_stagingArea.Get(_cacheKey)));
 }