public void CompareToSuccess() { StringKey newSK = new StringKey("0"); StringKey secondSK = new StringKey("1"); Assert.AreEqual(sk.CompareTo(newSK), 0); Assert.AreNotEqual(sk.CompareTo(secondSK), 0); }
public static void CompareToAphabeticallyAfterNameTest() { StringKey stringKey1 = new StringKey("A"); StringKey stringKey2 = new StringKey("B"); Assert.IsTrue(stringKey1.CompareTo(stringKey2) < 0); }
public static void CompareToSameObjectTest() { int expectedResult = 0; StringKey stringKey = new StringKey("Name"); Assert.AreEqual(expectedResult, stringKey.CompareTo(stringKey)); }
public static void CompareToSameNameTest() { int expectedResult = 0; StringKey stringKey1 = new StringKey("A"); StringKey stringKey2 = new StringKey("A"); Assert.AreEqual(expectedResult, stringKey1.CompareTo(stringKey2)); }