[TEST] Wait for yellow since some shards might not be started

In this test we only index a handful of docs so if we have more shards
than docs we might fail on the `assertSearchResult` since not all shards
are started but results are just fine.
This commit is contained in:
Simon Willnauer 2014-07-04 09:51:47 +02:00
parent 5249005578
commit a3d5cdcda8
1 changed files with 2 additions and 2 deletions

View File

@ -103,7 +103,7 @@ public class ExistsMissingTests extends ElasticsearchIntegrationTest {
expected.put("foobar", 0);
final long numDocs = client().prepareSearch("idx").execute().actionGet().getHits().totalHits();
ensureYellow("idx");
for (Map.Entry<String, Integer> entry : expected.entrySet()) {
final String fieldName = entry.getKey();
final int count = entry.getValue();