public void ToStringTest() { var testId = "FVVVVVVVVVVVU"; var id = new UnifiedId(testId); Assert.Equal(testId, id.ToString()); }
public void CompareToTest() { UnifiedId id = "FVVVVVVVVVVVU"; UnifiedId id2 = ulong.MaxValue - 1; Assert.Equal(0, id.CompareTo(id2)); Assert.Equal(0, id.CompareTo(id2.ToString())); Assert.Equal(1, id.CompareTo(string.Empty)); Assert.Equal(0, id.CompareTo(id2.ToInt64())); Assert.Equal(1, id.CompareTo(new object())); Assert.Equal(-1, id.CompareTo(ulong.MaxValue)); Assert.Equal(-1, id.CompareTo(new UnifiedId(ulong.MaxValue))); Assert.Equal(1, id.CompareTo(UnifiedId.Empty)); }