fix style

This commit is contained in:
Han Fei 2023-11-27 22:03:05 +01:00
parent 347efc669e
commit 8e1b61cc13

View File

@ -17,9 +17,11 @@ node = cluster.add_instance(
with_zookeeper=True, with_zookeeper=True,
) )
def random_string(length): def random_string(length):
return "".join(random.choices(string.ascii_lowercase + string.digits, k=length)) return "".join(random.choices(string.ascii_lowercase + string.digits, k=length))
def get_connection_zk(nodename, timeout=30.0): def get_connection_zk(nodename, timeout=30.0):
_fake_zk_instance = KazooClient( _fake_zk_instance = KazooClient(
hosts=cluster.get_instance_ip(nodename) + ":9181", timeout=timeout hosts=cluster.get_instance_ip(nodename) + ":9181", timeout=timeout
@ -38,6 +40,7 @@ def started_cluster():
finally: finally:
cluster.shutdown() cluster.shutdown()
def test_soft_limit_create(started_cluster): def test_soft_limit_create(started_cluster):
keeper_utils.wait_until_connected(started_cluster, node) keeper_utils.wait_until_connected(started_cluster, node)
try: try: