diff --git a/muted-tests.yml b/muted-tests.yml index 91ecd330c2194..edacc550d48b3 100644 --- a/muted-tests.yml +++ b/muted-tests.yml @@ -546,9 +546,6 @@ tests: - class: org.elasticsearch.xpack.esql.qa.multi_node.GenerativeIT method: test issue: https://github.com/elastic/elasticsearch/issues/131154 -- class: org.elasticsearch.xpack.esql.ccq.MultiClustersIT - method: testNotLikeListKeyword - issue: https://github.com/elastic/elasticsearch/issues/131155 - class: org.elasticsearch.index.engine.ThreadPoolMergeExecutorServiceDiskSpaceTests method: testEnqueuedMergeTasksAreUnblockedWhenEstimatedMergeSizeChanges issue: https://github.com/elastic/elasticsearch/issues/131165 diff --git a/x-pack/plugin/esql/qa/server/multi-clusters/src/javaRestTest/java/org/elasticsearch/xpack/esql/ccq/MultiClustersIT.java b/x-pack/plugin/esql/qa/server/multi-clusters/src/javaRestTest/java/org/elasticsearch/xpack/esql/ccq/MultiClustersIT.java index 7fa6d789bc8fc..4b6097f27047f 100644 --- a/x-pack/plugin/esql/qa/server/multi-clusters/src/javaRestTest/java/org/elasticsearch/xpack/esql/ccq/MultiClustersIT.java +++ b/x-pack/plugin/esql/qa/server/multi-clusters/src/javaRestTest/java/org/elasticsearch/xpack/esql/ccq/MultiClustersIT.java @@ -629,10 +629,16 @@ public void testNotLikeListKeyword() throws Exception { """, includeCCSMetadata); var columns = List.of(Map.of("name", "c", "type", "long"), Map.of("name", "_index", "type", "keyword")); Predicate filter = d -> false == (d.color.contains("blue") || d.color.contains("red")); - var values = List.of( - List.of((int) remoteDocs.stream().filter(filter).count(), REMOTE_CLUSTER_NAME + ":" + remoteIndex), - List.of((int) localDocs.stream().filter(filter).count(), localIndex) - ); + + var values = new ArrayList<>(); + int remoteCount = (int) remoteDocs.stream().filter(filter).count(); + int localCount = (int) localDocs.stream().filter(filter).count(); + if (remoteCount > 0) { + values.add(List.of(remoteCount, REMOTE_CLUSTER_NAME + ":" + remoteIndex)); + } + if (localCount > 0) { + values.add(List.of(localCount, localIndex)); + } assertResultMapForLike(includeCCSMetadata, result, columns, values, false, true); }