Esempio n. 1
0
        public void IndexOfTest()
        {
            // Arrange
            LimitedList <object> list = new LimitedList <object>(2);
            var obj1 = new Object();
            var obj2 = new Object();

            list.Add(obj1);
            list.Add(obj2);

            // Act
            int i1 = list.IndexOf(obj1);
            int i2 = list.IndexOf(obj2);

            // Assert
            Assert.AreEqual(0, i1);
            Assert.AreEqual(1, i2);
        }