On Mon, 9 Jun 2025 14:19:04 GMT, Daniel Fuchs <dfu...@openjdk.org> wrote:
>> p-nima has updated the pull request incrementally with one additional commit >> since the last revision: >> >> update summary > > test/jdk/java/net/httpclient/HttpClientAuthRetryLimitTest.java line 132: > >> 130: assertEquals("too many authentication attempts. Limit: >> " + RETRY_LIMIT, exception.getMessage()); >> 131: assertEquals(RETRY_LIMIT > 0 ? RETRY_LIMIT : 0, >> 132: RETRY_LIMIT > 0 ? >> requestCount.get():requestCount.decrementAndGet()); > > Could you split that in two statements for better readability? The double > ternary operator makes it difficult to parse. > > > if (RETRY_LIMIT > 0) { > assertEquals(...); > } else { > assertEquals(...); > } Also it would be better not to change the request count. The request count should only be changed by the Authenticator. Maybe introducing a variable: int expectedRequetedCount = ...; would be beneficial. ------------- PR Review Comment: https://git.openjdk.org/jdk/pull/25490#discussion_r2135819215