示例#1
0
        public void TestContains()
        {
            ShortList list = new ShortList();

            for (short j = 0; j < 1000; j += 2)
            {
                list.Add(j);
            }
            for (short j = 0; j < 1000; j++)
            {
                if (j % 2 == 0)
                {
                    Assert.IsTrue(list.Contains(j));
                }
                else
                {
                    Assert.IsTrue(!list.Contains(j));
                }
            }
        }