示例#1
0
        public void Configure_NewValueStaysFor1500ms_ButFailsFor2500ms()
        {
            var config = ConfigParams.FromTuples("timeout", 2000);

            _cache.Configure(config);

            var value = _cache.StoreAsync(null, Key3, Value3, 0).Result;
            var val3  = _cache.RetrieveAsync(null, Key3).Result;

            Assert.NotNull(val3);
            Assert.Equal(Value3, val3);

            Task.Delay(2500).Wait();

            val3 = _cache.RetrieveAsync(null, Key3).Result;
            Assert.Null(val3);
        }