diff --git a/src/test/java/org/elasticsearch/search/aggregations/bucket/FilterTests.java b/src/test/java/org/elasticsearch/search/aggregations/bucket/FilterTests.java index 1661abb557a..2089de8bbea 100644 --- a/src/test/java/org/elasticsearch/search/aggregations/bucket/FilterTests.java +++ b/src/test/java/org/elasticsearch/search/aggregations/bucket/FilterTests.java @@ -82,6 +82,7 @@ public class FilterTests extends ElasticsearchIntegrationTest { .endObject())); } indexRandom(true, builders.toArray(new IndexRequestBuilder[builders.size()])); + ensureGreen(); } @Test diff --git a/src/test/java/org/elasticsearch/search/aggregations/metrics/ValueCountTests.java b/src/test/java/org/elasticsearch/search/aggregations/metrics/ValueCountTests.java index 36f6aef44ea..c95e87dbefc 100644 --- a/src/test/java/org/elasticsearch/search/aggregations/metrics/ValueCountTests.java +++ b/src/test/java/org/elasticsearch/search/aggregations/metrics/ValueCountTests.java @@ -61,6 +61,7 @@ public class ValueCountTests extends ElasticsearchIntegrationTest { } client().admin().indices().prepareFlush().execute().actionGet(); client().admin().indices().prepareRefresh().execute().actionGet(); + ensureGreen(); } @Test