huan233usc commented on code in PR #17451:
URL: https://github.com/apache/iceberg/pull/17451#discussion_r3865594276
##########
core/src/test/java/org/apache/iceberg/StatsTestUtil.java:
##########
@@ -207,6 +220,8 @@ static FieldStats<Object> mockFieldStats(
Mockito.when(stats.nanValueCount()).thenReturn(nanCount);
}
+ Mockito.when(stats.avgValueSizeInBytes()).thenReturn(avgValueSize);
Review Comment:
Digging deeper, maybe just keep the unconditional stub here as it's aligned
with prod — a real `FieldStats` (`FieldStatsStruct`/`TestFieldStats`) returns
`null`, not `0`, for an untracked avg size, so guarding it lets the mock
default to `0` and read back as present, failing `TestTrackedFileAdapters`.
--
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]