public void UntokenizedAnalyzer_lower_cases_and_produces_single_token() { var reader = new StringReader("FOO bar"); var analyzer = new UntokenizedAnalyzer(); var tokenStream = analyzer.TokenStream("x", reader); var first = tokenStream.Next(); Assert.AreEqual("foo bar", first.Term()); Assert.IsNull(tokenStream.Next()); }
public void UntokenizedAnalyzer_does_not_drop_stopword_from_query() { var analyzer = new UntokenizedAnalyzer(); QueryParser parser = new QueryParser("x", analyzer); Assert.AreEqual("x:a", parser.Parse("a").ToString()); }