You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jira@kafka.apache.org by GitBox <gi...@apache.org> on 2022/06/19 09:51:54 UTC

[GitHub] [kafka] vamossagar12 commented on a diff in pull request #12307: KAFKA-14006: Parameterize WorkerConnectorTest suite

vamossagar12 commented on code in PR #12307:
URL: https://github.com/apache/kafka/pull/12307#discussion_r901070454


##########
connect/runtime/src/test/java/org/apache/kafka/connect/runtime/WorkerConnectorTest.java:
##########
@@ -142,11 +174,13 @@ public void testFailureIsFinalState() {
         ctx.close();
         expectLastCall();
 
-        offsetStorageReader.close();
-        expectLastCall();
+        if (connectorType == ConnectorType.SOURCE) {
+            offsetStorageReader.close();
+            expectLastCall();
 
-        offsetStore.stop();
-        expectLastCall();
+            offsetStore.stop();
+            expectLastCall();
+        }

Review Comment:
   I see these lines repeat in a few tests. Would it be better to move them to a separate method and invoke that method here?



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