From 1e0c0084cdc71be770c6e290944e793b952dde23 Mon Sep 17 00:00:00 2001 From: discord9 Date: Wed, 11 Nov 2026 12:25:28 +0800 Subject: [PATCH] test(promql): read a tree line by the node it names The composition test looked for a path prefix in front of the node name, which the bracketed tree no longer prints; the node name itself is the first word of every line. Signed-off-by: discord9 --- tests-integration/tests/http.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tests-integration/tests/http.rs b/tests-integration/tests/http.rs index dd98c664a56..aa3fbdf4727 100644 --- a/tests-integration/tests/http.rs +++ b/tests-integration/tests/http.rs @@ -5909,9 +5909,9 @@ async fn native_histogram_composition_query( assert!( descriptions.iter().any(|description| { description.lines().any(|line| { - let mut words = line.split_whitespace(); - matches!(words.next(), Some("root" | "input" | "left" | "right")) - && words.next() == Some("Binary") + // A tree line names its node first, so a `Binary` line is a binary node wherever it + // sits in the tree. + matches!(line.split_whitespace().next(), Some("Binary" | "Binary:")) }) }), "`{query}` did not execute a native Binary: {descriptions:?}; response: {body}"