xiangfu0 commented on code in PR #19795:
URL: https://github.com/apache/pinot/pull/19795#discussion_r4222561822
##########
pinot-core/src/test/java/org/apache/pinot/core/query/aggregation/function/PercentileSmartTDigestAggregationFunctionTest.java:
##########
@@ -119,7 +121,7 @@ public void
testMaterializedCapacityPreservingStateSerializesLegacyCompatible()
byte[] serialized =
function.serializeIntermediateResult(merged).getBytes();
assertLegacyCompatibleShape(serialized, 20.0);
Review Comment:
**[test reuse] This file keeps a private, weaker
`assertLegacyCompatibleShape` (~line 317) while also calling the shared,
stronger
`PercentileRawTDigestAggregationFunctionTest.assertLegacyCompatibleShape`
(lines 86/100).** The private copy does not validate the small-encoding
capacity fields (mainCapacity >= centroidCount, bufferCapacity >= mainCapacity)
or remaining-byte length, so the tests routed through it (here and lines 59/65)
skip exactly the capacity-preservation checks this PR is about. Delete the
private copy and use the shared helper everywhere.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]