Beispiel #1
0
        public void ShouldNotThrowExceptionWhenNotEmptyCheckNullCollection()
        {
            IEnumerable <string> enumerable = null;
            var action = new Action(() => Should.NotEmpty(enumerable, () => new CodeException()));

            action.Should().Throw <CodeException>();
        }
Beispiel #2
0
 public void ShouldNotThrowExceptionWhenNotEmptyCheckNotEmptyCollection()
 {
     Should.NotEmpty(new[] { 1 }, () => new CodeException());
 }
Beispiel #3
0
        public void ShouldNotThrowExceptionWhenNotEmptyCheckEmptyCollection()
        {
            var action = new Action(() => Should.NotEmpty(new string[0], () => new CodeException()));

            action.Should().Throw <CodeException>();
        }
Beispiel #4
0
        public void ShouldThrowExceptionWhenNotEmptyCheckNullString()
        {
            var action = new Action(() => Should.NotEmpty(null, () => new CodeException()));

            action.Should().Throw <CodeException>();
        }
Beispiel #5
0
 public void ShouldNotThrowExceptionWhenNotEmptyCheckNotEmptyString()
 {
     Should.NotEmpty("a", () => new CodeException());
     Should.NotEmpty(" ", () => new CodeException());
     Should.NotEmpty("\t", () => new CodeException());
 }
Beispiel #6
0
        public void ShouldNotThrowExceptionWhenNotEmptyCheckNullCollection()
        {
            IEnumerable <string> enumerable = null;

            Should.NotEmpty(enumerable, () => new CodeException());
        }
Beispiel #7
0
 public void ShouldNotThrowExceptionWhenNotEmptyCheckEmptyCollection()
 {
     Should.NotEmpty(new string[0], () => new CodeException());
 }
Beispiel #8
0
 public void ShouldThrowExceptionWhenNotEmptyCheckNullString()
 {
     Should.NotEmpty(null, () => new CodeException());
 }