public void TestKeyRangeToStringPrefix() { var keyrange = new KeyRange <string>(Key <string> .CreateKey("3", true), Key <string> .CreatePrefixKey("4")); string s = keyrange.ToString(); Assert.IsNotNull(s); Assert.AreNotEqual(s, String.Empty); StringAssert.Contains(s, "3"); StringAssert.Contains(s, "4"); StringAssert.Contains(s, "prefix"); }
public void TestKeyRangeToStringExclusive() { var keyrange = new KeyRange <int>(Key <int> .CreateKey(1, false), Key <int> .CreateKey(2, false)); string s = keyrange.ToString(); Assert.IsNotNull(s); Assert.AreNotEqual(s, String.Empty); StringAssert.Contains(s, "1"); StringAssert.Contains(s, "2"); StringAssert.Contains(s, "exclusive"); }
public void TestKeyRangeToStringInclusive() { var keyrange = new KeyRange <int>(Key <int> .CreateKey(3, true), Key <int> .CreateKey(4, true)); string s = keyrange.ToString(); Assert.IsNotNull(s); Assert.AreNotEqual(s, String.Empty); StringAssert.Contains(s, "3"); StringAssert.Contains(s, "4"); StringAssert.Contains(s, "inclusive"); }
// TODO: Use ScanTokenPB to generate ToString() public override string ToString() => _keyRange.ToString();