SOLR-11054: In SoftAutoCommitTest.testSoftAndHardCommitMaxDocs() all indexed docs must be searchable

This commit is contained in:
Cao Manh Dat 2017-08-21 15:36:17 +07:00
parent 9d8d3b0f29
commit 04956b8a90
1 changed files with 6 additions and 0 deletions

View File

@ -152,6 +152,12 @@ public class SoftAutoCommitTest extends AbstractSolrTestCase {
minHardCommitNanos + "ns",
minHardCommitNanos < firstHardNanos);
final Long firstSearcherNanos = monitor.searcher.poll(5000, MILLISECONDS);
assertNotNull("didn't get a single new searcher", firstSearcherNanos);
for (int i = 0; i <= softCommitMaxDocs; i++) {
assertQ("should find one", req("id:"+(8000 + i)) ,"//result[@numFound=1]" );
}
// wait a bit, w/o other action we shouldn't see any new hard/soft commits
assertNull("Got a hard commit we weren't expecting",
monitor.hard.poll(1000, MILLISECONDS));