You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lucene.apache.org by ho...@apache.org on 2018/10/31 22:36:32 UTC

[2/2] lucene-solr:branch_7x: SOLR-12946: tighten up request/expectations in test

SOLR-12946: tighten up request/expectations in test

This should prevent some non-reproducible failures where (i think) the problem was inconsistnet background merges between collections being compared, resulting in facet counts (of 0) for terms that weren't in equivilent (merged) indexes.

since the purpose of the test has nothing to do with mincount, force facet.mincount=0 and be more exact about how many terms we expect (in case the root problem lies somewhere else, be more assertive about finding it)

(cherry picked from commit 05f72a77efb13517885618597f14cf0d76bd31f7)


Project: http://git-wip-us.apache.org/repos/asf/lucene-solr/repo
Commit: http://git-wip-us.apache.org/repos/asf/lucene-solr/commit/50e10d32
Tree: http://git-wip-us.apache.org/repos/asf/lucene-solr/tree/50e10d32
Diff: http://git-wip-us.apache.org/repos/asf/lucene-solr/diff/50e10d32

Branch: refs/heads/branch_7x
Commit: 50e10d327428ea05df493e6bcd62aaeccb7ec0b9
Parents: a852ebc
Author: Chris Hostetter <ho...@apache.org>
Authored: Wed Oct 31 15:33:39 2018 -0700
Committer: Chris Hostetter <ho...@apache.org>
Committed: Wed Oct 31 15:33:55 2018 -0700

----------------------------------------------------------------------
 .../src/test/org/apache/solr/cloud/DistribCursorPagingTest.java    | 2 ++
 1 file changed, 2 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/lucene-solr/blob/50e10d32/solr/core/src/test/org/apache/solr/cloud/DistribCursorPagingTest.java
----------------------------------------------------------------------
diff --git a/solr/core/src/test/org/apache/solr/cloud/DistribCursorPagingTest.java b/solr/core/src/test/org/apache/solr/cloud/DistribCursorPagingTest.java
index 46f77c0..59be08a 100644
--- a/solr/core/src/test/org/apache/solr/cloud/DistribCursorPagingTest.java
+++ b/solr/core/src/test/org/apache/solr/cloud/DistribCursorPagingTest.java
@@ -253,12 +253,14 @@ public class DistribCursorPagingTest extends AbstractFullDistribZkTestBase {
                     "fl", "id",
                     "facet", "true",
                     "facet.field", "str",
+                    "facet.mincount", "1",
                     "json.nl", "map",
                     "sort", intsort + " asc, id asc");
     rsp = query(p(params, CURSOR_MARK_PARAM, cursorMark));
     assertNumFound(8, rsp);
     assertStartsAt(0, rsp);
     assertDocList(rsp, 7, 0, 3);
+    assertEquals(3, rsp.getFacetField("str").getValues().size());
     assertEquals("a", rsp.getFacetField("str").getValues().get(0).getName());
     assertEquals(4, rsp.getFacetField("str").getValues().get(0).getCount());
     cursorMark = assertHashNextCursorMark(rsp);