mirror of https://github.com/apache/lucene.git
LUCENE-3099: fix AllGroupsCollectorTest
git-svn-id: https://svn.apache.org/repos/asf/lucene/dev/trunk@1130859 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
d1548ca30a
commit
526d6c937e
|
@ -91,15 +91,15 @@ public class AllGroupsCollectorTest extends LuceneTestCase {
|
||||||
IndexSearcher indexSearcher = new IndexSearcher(w.getReader());
|
IndexSearcher indexSearcher = new IndexSearcher(w.getReader());
|
||||||
w.close();
|
w.close();
|
||||||
|
|
||||||
AllGroupsCollector c1 = new AllGroupsCollector(groupField);
|
TermAllGroupsCollector c1 = new TermAllGroupsCollector(groupField);
|
||||||
indexSearcher.search(new TermQuery(new Term("content", "random")), c1);
|
indexSearcher.search(new TermQuery(new Term("content", "random")), c1);
|
||||||
assertEquals(4, c1.getGroupCount());
|
assertEquals(4, c1.getGroupCount());
|
||||||
|
|
||||||
AllGroupsCollector c2 = new AllGroupsCollector(groupField);
|
TermAllGroupsCollector c2 = new TermAllGroupsCollector(groupField);
|
||||||
indexSearcher.search(new TermQuery(new Term("content", "some")), c2);
|
indexSearcher.search(new TermQuery(new Term("content", "some")), c2);
|
||||||
assertEquals(3, c2.getGroupCount());
|
assertEquals(3, c2.getGroupCount());
|
||||||
|
|
||||||
AllGroupsCollector c3 = new AllGroupsCollector(groupField);
|
TermAllGroupsCollector c3 = new TermAllGroupsCollector(groupField);
|
||||||
indexSearcher.search(new TermQuery(new Term("content", "blob")), c3);
|
indexSearcher.search(new TermQuery(new Term("content", "blob")), c3);
|
||||||
assertEquals(2, c3.getGroupCount());
|
assertEquals(2, c3.getGroupCount());
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue