Jiabao-Sun commented on code in PR #24483: URL: https://github.com/apache/flink/pull/24483#discussion_r1524267664
########## flink-streaming-java/src/test/java/org/apache/flink/streaming/runtime/tasks/OneInputStreamTaskTest.java: ########## @@ -895,39 +890,38 @@ public TaskMetricGroup getMetricGroup() { (Gauge<Long>) chainedOperatorMetricGroup.get(MetricNames.IO_CURRENT_OUTPUT_WATERMARK); - Assert.assertEquals( - "A metric was registered multiple times.", - 5, - new HashSet<>( + assertThat( Review Comment: > the only reason for collecting the retrieved Gauge instances to a Set is to validate that none of them are null Here, we are not checking for null; rather, we are examining whether there are duplicates among the five `Gauge`s to ensure that no metric has been registered multiple times. -- 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: issues-unsubscr...@flink.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org