Example #1
0
        public void CollectionFailedTest()
        {
            const string johnDoe = "John Doe";
            const string janeDoe = "Jane Doe";

            var list = new List <object>
            {
                johnDoe,
                janeDoe
            };

            Assert.Throws <CollectionException>(() => Verify.Collection(list, item => Assert.Equal(johnDoe, item)));
        }
Example #2
0
        public void CollectionTest()
        {
            const string johnDoe = "John Doe";
            const string janeDoe = "Jane Doe";

            var list = new List <object>
            {
                johnDoe,
                janeDoe
            };

            Verify.Collection(list, item => Assert.Equal(johnDoe, item),
                              item => Assert.Equal(janeDoe, item));
        }