public void GDIDWithISOKey_CreateNotEquate_1() { var k1 = new GDIDWithISOKey(new GDID(10, 20), "eng"); var k2 = new GDIDWithISOKey(new GDID(10, 21), "eNG"); Aver.AreNotEqual(k1, k2); Aver.IsFalse(k1.Equals(k2)); var o = k2; Aver.IsFalse(k1.Equals(o)); Aver.AreNotEqual(k1.GetHashCode(), k2.GetHashCode()); Aver.AreNotEqual(k1.GetDistributedStableHash(), k2.GetDistributedStableHash()); Console.WriteLine(k1.ToString()); }
public void GDIDWithISOKey_CreateEquate_2() { var k1 = new GDIDWithISOKey(new GDID(10, 20), "ua"); var k2 = new GDIDWithISOKey(new GDID(10, 20), "UA"); Aver.AreEqual("UA", k1.ISOCode); Aver.AreEqual("UA", k2.ISOCode); Aver.AreEqual(k1, k2); Aver.IsTrue(k1.Equals(k2)); var o = k2; Aver.IsTrue(k1.Equals(o)); Aver.AreEqual(k1.GetHashCode(), k2.GetHashCode()); Aver.AreEqual(k1.GetDistributedStableHash(), k2.GetDistributedStableHash()); Console.WriteLine(k1.ToString()); }
public void GDIDWithISOKey_CreateNotEquate_3() { var k1 = new GDIDWithISOKey(new GDID(10, 20), "en"); var k2 = new GDIDWithISOKey(new GDID(10, 20), "fr"); Assert.AreNotEqual(k1, k2); Assert.IsFalse(k1.Equals(k2)); var o = k2; Assert.IsFalse(k1.Equals(o)); Assert.AreNotEqual(k1.GetHashCode(), k2.GetHashCode()); Assert.AreNotEqual(k1.GetDistributedStableHash(), k2.GetDistributedStableHash()); Console.WriteLine(k1.ToString()); }
public void GDIDWithISOKey_CreateEquate_2() { var k1 = new GDIDWithISOKey(new GDID(10, 20), "ua"); var k2 = new GDIDWithISOKey(new GDID(10, 20), "UA"); Assert.AreEqual("UA", k1.ISOCode); Assert.AreEqual("UA", k2.ISOCode); Assert.AreEqual(k1, k2); Assert.IsTrue(k1.Equals(k2)); var o = k2; Assert.IsTrue(k1.Equals(o)); Assert.AreEqual(k1.GetHashCode(), k2.GetHashCode()); Assert.AreEqual(k1.GetDistributedStableHash(), k2.GetDistributedStableHash()); Console.WriteLine(k1.ToString()); }