Пример #1
0
        public void WhenArgNotGreaterThanTwo_ThrowException()
        {
            const int myArg = 1;

            Assert.Throws <ArgumentOutOfRangeException>(() => ArgValidator.GreaterThan(myArg, 2, nameof(myArg)));
        }
Пример #2
0
        public void WhenArgGreaterThenTwo_ThenDoNotThrowException()
        {
            const int myArg = 3;

            Assert.DoesNotThrow(() => ArgValidator.GreaterThan(myArg, 2, nameof(myArg)));
        }