public static void IndexIsInRange(System.Collections.IList list, int index, string message)
 {
     if (!list.IndexIsInRange(index))
     {
         Fail(AssertionMessageUtil.IndexOutOfRangeMessage(index, list.Count), message);
     }
 }
 public static void IsNull(object value, string message)
 {
     if (value != null)
     {
         Fail(AssertionMessageUtil.NullFailureMessage(value, expectNull: true), message);
     }
 }
 public static void IsNotNull(Object value, string message)
 {
     if (value == null)
     {
         Fail(AssertionMessageUtil.NullFailureMessage(value, expectNull: false), message);
     }
 }
 public static void IsNot(bool actual, bool expected, string because)
 {
     if (actual == expected)
     {
         Fail(AssertionMessageUtil.BooleanFailureMessage(expected), because);
     }
 }
 public static void IsFalse(bool condition, string message)
 {
     if (condition)
     {
         Fail(AssertionMessageUtil.BooleanFailureMessage(expected: false), message);
     }
 }
 public static void AreNotEqual(Object expected, Object actual, string message)
 {
     if (actual == expected)
     {
         Fail(AssertionMessageUtil.GetEqualityMessage(
                  actual, expected, expectEqual: false), message);
     }
 }
 public static void IsNotNull <T>(T value, string message) where T : class
 {
     if (typeof(Object).IsAssignableFrom(typeof(T)))
     {
         IsNotNull(value as Object, message);
     }
     else if (value == null)
     {
         Fail(AssertionMessageUtil.NullFailureMessage(value, expectNull: false), message);
     }
 }
 public static void AreNotEqual <T>(T expected, T actual,
                                    string message, IEqualityComparer <T> comparer)
 {
     if (typeof(Object).IsAssignableFrom(typeof(T)))
     {
         AreNotEqual(expected as Object, actual as Object, message);
     }
     else if (comparer.Equals(actual, expected))
     {
         Fail(AssertionMessageUtil.GetEqualityMessage(actual,
                                                      expected, expectEqual: false), message);
     }
 }