示例#1
0
        public void TestTwoMarkListRemoveExpiredOneOld()
        {
            MarkManager marks = new MarkManager();

            marks.Mark();
            marks.Mark(DateTime.Now.AddHours(-1));

            marks.RemoveExpiredMarks();

            Assert.AreEqual(1, marks.Marks.Count);
        }
示例#2
0
        public void TestTwentyMarkListClosedWindow()
        {
            MarkManager marks = new MarkManager();

            for (var count = 0; count < 20; count++) {
                marks.Mark();
            }

            Assert.IsFalse(marks.IsValidMarkWindow());
        }