diff --git a/modules/percolator/src/test/java/org/elasticsearch/percolator/PercolatorQuerySearchIT.java b/modules/percolator/src/test/java/org/elasticsearch/percolator/PercolatorQuerySearchIT.java index ce8e871e51de3..f7701bfa96be4 100644 --- a/modules/percolator/src/test/java/org/elasticsearch/percolator/PercolatorQuerySearchIT.java +++ b/modules/percolator/src/test/java/org/elasticsearch/percolator/PercolatorQuerySearchIT.java @@ -956,6 +956,11 @@ public void testWrappedWithConstantScore() throws Exception { BytesReference.bytes(jsonBuilder().startObject().field("d", "2020-02-01T15:00:00.000+11:00").endObject()), XContentType.JSON)).get(); assertEquals(1, response.getHits().getTotalHits().value); + + response = client().prepareSearch("test").setQuery(new PercolateQueryBuilder("q", + BytesReference.bytes(jsonBuilder().startObject().field("d", "2020-02-01T15:00:00.000+11:00").endObject()), + XContentType.JSON)).addSort("_doc", SortOrder.ASC).get(); + assertEquals(1, response.getHits().getTotalHits().value); response = client().prepareSearch("test").setQuery(constantScoreQuery(new PercolateQueryBuilder("q", BytesReference.bytes(jsonBuilder().startObject().field("d", "2020-02-01T15:00:00.000+11:00").endObject()),