Skip to content

Commit a9e7812

Browse files
committed
revert unnecessary change
1 parent 38fae02 commit a9e7812

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

tests/pulsar_test.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -158,7 +158,7 @@ def send_callback(producer, msg):
158158

159159
def test_producer_send(self):
160160
client = Client(self.serviceUrl)
161-
topic = f"test_producer_send_{time.time()}"
161+
topic = "test_producer_send"
162162
producer = client.create_producer(topic)
163163
consumer = client.subscribe(topic, "sub-name")
164164
msg_id = producer.send(b"hello")
@@ -550,8 +550,7 @@ def verify_next_message(value: bytes):
550550
def verify_undecrypted_message(msg: pulsar.Message, i: int):
551551
self.assertNotEqual(msg.data(), f"msg-{i}".encode())
552552
self.assertTrue(len(msg.data()) > 5, f"msg.data() is {msg.data()}")
553-
batch_size = 2 if i >=3 else -1
554-
verify_encryption_context(msg.encryption_context(), True, batch_size)
553+
verify_encryption_context(msg.encryption_context(), True, 2 if i >= 3 else -1)
555554

556555
# Encrypted messages will be consumed since the crypto failure action is CONSUME
557556
consumer = client.subscribe(topic, 'another-sub',

0 commit comments

Comments
 (0)