mingyen066 commented on code in PR #18781: URL: https://github.com/apache/kafka/pull/18781#discussion_r1941420485
########## clients/src/test/java/org/apache/kafka/clients/ClientUtilsTest.java: ########## @@ -95,6 +99,34 @@ public void testParseAndValidateAddressesWithReverseLookup() { } } + static Stream<List<String>> provideValidBrokerAddressTestCases() { + return Stream.of( + List.of("localhost:9997", "localhost:9998", "localhost:9999") + ); + } + + @ParameterizedTest + @MethodSource("provideValidBrokerAddressTestCases") + public void testValidBrokerAddress(List<String> addresses) { + assertDoesNotThrow(() -> ClientUtils.parseAndValidateAddresses(addresses, ClientDnsLookup.USE_ALL_DNS_IPS)); + } Review Comment: I thought I would be convenient to add more cases. But for readibility, I will just eliminate `@methodSouce` -- 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: jira-unsubscr...@kafka.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org