You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jira@kafka.apache.org by "lucasbru (via GitHub)" <gi...@apache.org> on 2025/09/10 18:39:01 UTC
Re: [PR] MINOR: Deflake and improve SmokeTestDriverIntegrationTest [kafka]
lucasbru commented on code in PR #20509:
URL: https://github.com/apache/kafka/pull/20509#discussion_r2337601415
##########
streams/integration-tests/src/test/java/org/apache/kafka/streams/integration/SmokeTestDriverIntegrationTest.java:
##########
@@ -46,29 +47,43 @@
import static org.apache.kafka.streams.tests.SmokeTestDriver.generate;
import static org.apache.kafka.streams.tests.SmokeTestDriver.verify;
import static org.apache.kafka.streams.utils.TestUtils.safeUniqueTestName;
+import static org.junit.jupiter.api.Assertions.assertFalse;
import static org.junit.jupiter.api.Assertions.assertTrue;
@Timeout(600)
@Tag("integration")
public class SmokeTestDriverIntegrationTest {
- public static final EmbeddedKafkaCluster CLUSTER = new EmbeddedKafkaCluster(3);
+ public static EmbeddedKafkaCluster cluster = null;
public TestInfo testInfo;
+ public ArrayList<SmokeTestClient> clients = new ArrayList<>();
@BeforeAll
public static void startCluster() throws IOException {
- CLUSTER.start();
+ cluster = new EmbeddedKafkaCluster(3);
Review Comment:
By recreating the embeddedKafkaCluster in `@BeforeAll`, we can run the test more than once to deflake it better.
--
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: jira-unsubscribe@kafka.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org