HQebupt commented on code in PR #17315:
URL: https://github.com/apache/pulsar/pull/17315#discussion_r970873551
##########
pulsar-broker/src/test/java/org/apache/pulsar/broker/service/ServerCnxTest.java:
##########
@@ -2307,4 +2308,21 @@ public void handleConnectWithServiceNotReady() throws
Exception {
assertEquals(error.getError(), ServerError.ServiceNotReady);
channel.finish();
}
+
+ @Test(timeOut = 30000)
+ public void handlePartitionMetadataRequestWithServiceNotReady() throws
Exception {
+ resetChannel();
+ setChannelConnected();
+ CompletableFuture<Boolean> successFuture =
CompletableFuture.completedFuture(true);
+
doReturn(successFuture).when(namespaceService).checkTopicExists(any(TopicName.class));
Review Comment:
No. It will make the test case more complex. I think it's not worth it .
--
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]