public void MatchIndexIsCorrectlyOffsetWhenUsingStartIndex() { string source = "Some St!ring"; var matcher = new ExcludeStringMatcher(source); matcher.SetStartIndex(5); Assert.Equal(7, matcher.FindNextIndex('!')); }
public void DoesntFindAMatchWhenMatchIsBeforeStartIndex() { string source = "Some!String"; var matcher = new ExcludeStringMatcher(source); matcher.SetStartIndex(5); Assert.Null(matcher.FindNextIndex('!')); }