You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@kafka.apache.org by ch...@apache.org on 2023/02/26 17:57:37 UTC
[kafka] branch trunk updated: MINOR: Replace String literal with existing String variable (#13305)
This is an automated email from the ASF dual-hosted git repository.
chia7712 pushed a commit to branch trunk
in repository https://gitbox.apache.org/repos/asf/kafka.git
The following commit(s) were added to refs/heads/trunk by this push:
new dfd8fdb859a MINOR: Replace String literal with existing String variable (#13305)
dfd8fdb859a is described below
commit dfd8fdb859a7660c01522c4dca5269771d5491d7
Author: Hoki Min <ho...@gmail.com>
AuthorDate: Mon Feb 27 02:57:20 2023 +0900
MINOR: Replace String literal with existing String variable (#13305)
Reviewers: Divij Vaidya <di...@amazon.com>, Chia-Ping Tsai <ch...@gmail.com>
---
.../kafka/clients/producer/internals/DefaultPartitionerTest.java | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/clients/src/test/java/org/apache/kafka/clients/producer/internals/DefaultPartitionerTest.java b/clients/src/test/java/org/apache/kafka/clients/producer/internals/DefaultPartitionerTest.java
index c851408f363..2af61806a34 100644
--- a/clients/src/test/java/org/apache/kafka/clients/producer/internals/DefaultPartitionerTest.java
+++ b/clients/src/test/java/org/apache/kafka/clients/producer/internals/DefaultPartitionerTest.java
@@ -46,7 +46,7 @@ public class DefaultPartitionerTest {
final Partitioner partitioner = new DefaultPartitioner();
final Cluster cluster = new Cluster("clusterId", asList(NODES), PARTITIONS,
Collections.emptySet(), Collections.emptySet());
- int partition = partitioner.partition("test", null, KEY_BYTES, null, null, cluster);
- assertEquals(partition, partitioner.partition("test", null, KEY_BYTES, null, null, cluster), "Same key should yield same partition");
+ int partition = partitioner.partition(TOPIC, null, KEY_BYTES, null, null, cluster);
+ assertEquals(partition, partitioner.partition(TOPIC, null, KEY_BYTES, null, null, cluster), "Same key should yield same partition");
}
}