Copilot commented on code in PR #170: URL: https://github.com/apache/olingo-odata4/pull/170#discussion_r2249485507
########## fit/src/test/java/org/apache/olingo/fit/tecsvc/http/ODataVersionConformanceITCase.java: ########## @@ -112,12 +111,13 @@ public void validODataVersionAndMaxVersionHeader() throws Exception { connection.setRequestProperty(HttpHeader.ODATA_MAX_VERSION, "5.0"); connection.connect(); + assertEquals(HttpStatusCode.OK.getStatusCode(), connection.getResponseCode()); Review Comment: Similar to the previous issue, the test checks for OK status but reads from getErrorStream() in line 117. This is inconsistent - either expect an error status or read from getInputStream(). ########## fit/src/test/java/org/apache/olingo/fit/tecsvc/http/ODataVersionConformanceITCase.java: ########## @@ -96,9 +94,10 @@ public void validODataMaxVersionHeader() throws Exception { connection.setRequestProperty(HttpHeader.ODATA_MAX_VERSION, "5.0"); connection.connect(); + assertEquals(HttpStatusCode.OK.getStatusCode(), connection.getResponseCode()); Review Comment: The test is checking for OK status but reading from getErrorStream() in line 100, which suggests the test expects an error response. Either the status assertion should expect an error code or line 100 should read from getInputStream(). -- 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: dev-unsubscr...@olingo.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org