public void when_not_contains_key() { var memory = new DuplicationMemory(); var result = memory.DoWeRemember("MemId"); Assert.IsFalse(result); }
public void when_exist_key() { var memory = new DuplicationMemory(); memory.Memorize("MemId"); var result = memory.DoWeRemember("MemId"); Assert.IsTrue(result); }
public void when_forget_older() { var memory = new DuplicationMemory(); memory.Memorize("MemId"); memory.ForgetOlderThan(new TimeSpan(0)); var result = memory.DoWeRemember("MemId"); Assert.IsFalse(result); }