Skip to content

Commit 4522b12

Browse files
committed
description for test
1 parent 85163f1 commit 4522b12

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

x-pack/plugin/esql/src/internalClusterTest/java/org/elasticsearch/xpack/esql/action/RandomizedTimeSeriesIT.java

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -341,6 +341,12 @@ void assertNoFailedWindows(List<String> failedWindows, List<List<Object>> rows)
341341
}
342342
}
343343

344+
/**
345+
* This test validates Rate metrics aggregation with grouping by time bucket and a subset of dimensions.
346+
* The subset of dimensions is a random subset of the dimensions present in the data.
347+
* The test checks that the count, max, min, and avg values of the rate metric - and calculates
348+
* the same values from the documents in the group.
349+
*/
344350
public void testRateGroupBySubset() {
345351
var dimensions = ESTestCase.randomNonEmptySubsetOf(dataGenerationHelper.attributesForMetrics);
346352
var dimensionsStr = dimensions.stream().map(d -> "attributes." + d).collect(Collectors.joining(", "));
@@ -380,6 +386,12 @@ public void testRateGroupBySubset() {
380386
}
381387
}
382388

389+
/**
390+
* This test validates Rate metrics aggregation with grouping by time bucket only.
391+
* The test checks that the count, max, min, and avg values of the rate metric - and calculates
392+
* the same values from the documents in the group. Because there is no grouping by dimensions,
393+
* there is only one metric group per time bucket.
394+
*/
383395
public void testRateGroupByNothing() {
384396
var groups = groupedRows(documents, List.of(), 60);
385397
try (var resp = run(String.format(Locale.ROOT, """

0 commit comments

Comments
 (0)