lianetm commented on code in PR #20664:
URL: https://github.com/apache/kafka/pull/20664#discussion_r2416952032
##########
tools/src/test/java/org/apache/kafka/tools/TopicCommandTest.java:
##########
@@ -1198,8 +1198,8 @@ public void
testDescribeUnderReplicatedPartitionsWhenReassignmentIsInProgress(Cl
"Unexpected describe output length: " +
simpleDescribeOutputRows.length);
String underReplicatedOutput =
captureDescribeTopicStandardOut(clusterInstance,
buildTopicCommandOptionsWithBootstrap(clusterInstance, "--describe",
"--under-replicated-partitions"));
- assertEquals("", underReplicatedOutput,
- String.format("--under-replicated-partitions shouldn't
return anything: '%s'", underReplicatedOutput));
+ assertFalse(underReplicatedOutput.contains(String.format("Topic:
%s", testTopicName)),
+ String.format("--under-replicated-partitions shouldn't
contain '%s': '%s'", String.format("Topic: %s", testTopicName),
underReplicatedOutput));
Review Comment:
nit: should we extract the string formatting bit to a var (good to reuse and
would be clearer)
--
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]