Exemplo n.º 1
0
        public void AddTest()
        {
            var t        = new TestTaskList <int>();
            var expected = new List <int>();

            for (var i = 0; i < 10; i++)
            {
                t.Add(i);
                expected.Add(i);
            }

            AssertContainSameElements(t, expected);
        }
Exemplo n.º 2
0
        public void RemoveLastTest()
        {
            var t        = new TestTaskList <int>();
            var expected = new List <int>();

            for (var i = 0; i < 10; i++)
            {
                t.Add(i);
                expected.Add(i);
            }

            AssertContainSameElements(t, expected);

            t.Perform(x => x == 0);
            expected.RemoveAll(x => x == 0);

            AssertContainSameElements(t, expected);
        }