Example #1
0
 public void AtMost_LessOrEqual_ReturnsValue(int AMaximum, int AValue)
 {
     Assert.That(
         Require.AtMost(AMaximum, AValue, nameof(AValue)),
         Is.EqualTo(AValue)
         );
 }
Example #2
0
        public void AtMost_Greater_ThrowsArgumentOutOfRangeException()
        {
            var ex = Assert.Throws <ArgumentOutOfRangeException>(
                () => Require.AtMost(0, 1, C_ParamName)
                );

            Assert.That(ex.ParamName, Is.EqualTo(C_ParamName));
        }