Exemple #1
0
        public void WhenContainsNull_ThrowsException()
        {
            var enumerable = new [] { new object(), null, new object() };

            Assert.Throws <ArgumentException>(
                () => RequireThat.DoesNotContainNull(enumerable, "name"));
        }
Exemple #2
0
 public void WhenNull_ThrowsException()
 {
     Assert.Throws <ArgumentNullException>(
         () => RequireThat.DoesNotContainNull(null as IEnumerable, "name"));
 }
Exemple #3
0
        public void WhenContainsNoNull_DoesNotThrow()
        {
            var enumerable = new[] { new object(), new object() };

            RequireThat.DoesNotContainNull(enumerable, "name");
        }