RongtongJin opened a new issue, #10412:
URL: https://github.com/apache/rocketmq/issues/10412

   ### Describe the bug
   
   
`BrokerOuterAPITest.testPullMessageFromSpecificBrokerAsync_brokerReturn_pullStatusCode`
 can fail intermittently in CI, especially on the macOS JDK8 Maven job.
   
   The failure observed on PR #10411 was:
   
   ```text
   
BrokerOuterAPITest.testPullMessageFromSpecificBrokerAsync_brokerReturn_pullStatusCode:361
 expected:<NO_NEW_MSG> but was:<FOUND>
   ```
   
   ### Root cause
   
   The test reuses a completed `DefaultChannelPromise` across multiple 
response-code scenarios and repeatedly re-stubs the same spy method in a loop. 
This makes the assertion depend on Netty listener scheduling and Mockito spy 
restubbing timing, so a later iteration can observe a previous response.
   
   ### Expected behavior
   
   Each response-code scenario should be isolated and deterministically drive 
the `InvokeCallback` response used by `BrokerOuterAPI`.
   


-- 
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]

Reply via email to