Пример #1
0
 public static void AreNotEqual(UnityEngine.Object expected, UnityEngine.Object actual, string message)
 {
     if (!(actual == expected))
     {
         return;
     }
     Assert.Fail(AssertionMessageUtil.GetEqualityMessage((object)actual, (object)expected, false), message);
 }
Пример #2
0
 public static void AreNotEqual(
     UnityEngine.Object expected,
     UnityEngine.Object actual,
     string message
     )
 {
     if (actual == expected)
     {
         Fail(AssertionMessageUtil.GetEqualityMessage(actual, expected, false), message);
     }
 }
Пример #3
0
 public static void AreNotEqual <T>(T expected, T actual, string message, IEqualityComparer <T> comparer)
 {
     if (typeof(UnityEngine.Object).IsAssignableFrom(typeof(T)))
     {
         Assert.AreNotEqual((object)expected as UnityEngine.Object, (object)actual as UnityEngine.Object,
                            message);
     }
     else
     {
         if (!comparer.Equals(actual, expected))
         {
             return;
         }
         Assert.Fail(AssertionMessageUtil.GetEqualityMessage((object)actual, (object)expected, false),
                     message);
     }
 }
Пример #4
0
 public static void AreEqual <T>(
     T expected,
     T actual,
     string message,
     IEqualityComparer <T> comparer
     )
 {
     if (typeof(UnityEngine.Object).IsAssignableFrom(typeof(T)))
     {
         AreEqual(expected as UnityEngine.Object, actual as UnityEngine.Object, message);
         return;
     }
     if (!comparer.Equals(actual, expected))
     {
         Fail(AssertionMessageUtil.GetEqualityMessage(actual, expected, true), message);
     }
 }