diff --git a/muted-tests.yml b/muted-tests.yml index 8f76dcd4159a6..98024aa8cd0ed 100644 --- a/muted-tests.yml +++ b/muted-tests.yml @@ -436,9 +436,6 @@ tests: - class: org.elasticsearch.xpack.esql.qa.single_node.GenerativeForkIT method: test {csv-spec:inlinestats.MvMinMvExpand} issue: https://github.com/elastic/elasticsearch/issues/137679 -- class: org.elasticsearch.xpack.esql.optimizer.rules.physical.local.SubstituteRoundToTests - method: testSubqueryWithCountStarAndDateTrunc {default} - issue: https://github.com/elastic/elasticsearch/issues/138601 - class: org.elasticsearch.xpack.ilm.TimeSeriesLifecycleActionsIT method: testWaitForSnapshot issue: https://github.com/elastic/elasticsearch/issues/138669 diff --git a/x-pack/plugin/esql/src/test/java/org/elasticsearch/xpack/esql/optimizer/rules/physical/local/SubstituteRoundToTests.java b/x-pack/plugin/esql/src/test/java/org/elasticsearch/xpack/esql/optimizer/rules/physical/local/SubstituteRoundToTests.java index a3be8fe82e078..c1fcd9d45c88f 100644 --- a/x-pack/plugin/esql/src/test/java/org/elasticsearch/xpack/esql/optimizer/rules/physical/local/SubstituteRoundToTests.java +++ b/x-pack/plugin/esql/src/test/java/org/elasticsearch/xpack/esql/optimizer/rules/physical/local/SubstituteRoundToTests.java @@ -16,6 +16,7 @@ import org.elasticsearch.index.query.QueryBuilder; import org.elasticsearch.index.query.RangeQueryBuilder; import org.elasticsearch.xpack.esql.EsqlTestUtils; +import org.elasticsearch.xpack.esql.action.EsqlCapabilities; import org.elasticsearch.xpack.esql.core.expression.Alias; import org.elasticsearch.xpack.esql.core.expression.Attribute; import org.elasticsearch.xpack.esql.core.expression.Expression; @@ -859,6 +860,7 @@ public void testForkWithStatsCountStarDateTrunc() { } public void testSubqueryWithCountStarAndDateTrunc() { + assumeTrue("requires subqueries in from", EsqlCapabilities.Cap.SUBQUERY_IN_FROM_COMMAND.isEnabled()); String query = """ from test, (from test | stats cnt = count(*) by x = date_trunc(1 day, date)) | keep x, cnt, date