Automatic style fix

This commit is contained in:
robot-clickhouse 2024-02-04 10:37:05 +00:00
parent b0994c5fa7
commit ce6df0fb13

View File

@ -47,7 +47,6 @@ def generate_cluster_def(port):
return path
@pytest.fixture(scope="module")
def cluster():
try:
@ -156,6 +155,7 @@ def delete_all_files(cluster):
yield
def test_backup_restore(cluster):
node = cluster.instances["node"]
port = cluster.env_variables["AZURITE_PORT"]
@ -184,6 +184,7 @@ def test_backup_restore(cluster):
== "1\ta\n"
)
def test_backup_restore_diff_container(cluster):
node = cluster.instances["node"]
port = cluster.env_variables["AZURITE_PORT"]
@ -204,7 +205,9 @@ def test_backup_restore_diff_container(cluster):
f"RESTORE TABLE test_simple_write_connection_string_cont1 AS test_simple_write_connection_string_restored_cont1 FROM {backup_destination};",
)
assert (
azure_query(node, f"SELECT * from test_simple_write_connection_string_restored_cont1")
azure_query(
node, f"SELECT * from test_simple_write_connection_string_restored_cont1"
)
== "1\ta\n"
)
@ -216,13 +219,13 @@ def test_backup_restore_with_named_collection_azure_conf1(cluster):
node,
f"CREATE TABLE test_write_connection_string (key UInt64, data String) Engine = AzureBlobStorage('{cluster.env_variables['AZURITE_CONNECTION_STRING']}', 'cont', 'test_simple_write.csv', 'CSV')",
)
azure_query(
node, f"INSERT INTO test_write_connection_string VALUES (1, 'a')"
)
azure_query(node, f"INSERT INTO test_write_connection_string VALUES (1, 'a')")
print(get_azure_file_content("test_simple_write.csv", port))
assert get_azure_file_content("test_simple_write.csv", port) == '1,"a"\n'
backup_destination = f"AzureBlobStorage(azure_conf1, 'test_simple_write_nc_backup.csv')"
backup_destination = (
f"AzureBlobStorage(azure_conf1, 'test_simple_write_nc_backup.csv')"
)
azure_query(
node,
f"BACKUP TABLE test_write_connection_string TO {backup_destination}",
@ -237,6 +240,7 @@ def test_backup_restore_with_named_collection_azure_conf1(cluster):
== "1\ta\n"
)
def test_backup_restore_with_named_collection_azure_conf2(cluster):
node = cluster.instances["node"]
port = cluster.env_variables["AZURITE_PORT"]
@ -244,13 +248,13 @@ def test_backup_restore_with_named_collection_azure_conf2(cluster):
node,
f"CREATE TABLE test_write_connection_string_2 (key UInt64, data String) Engine = AzureBlobStorage('{cluster.env_variables['AZURITE_CONNECTION_STRING']}', 'cont', 'test_simple_write_2.csv', 'CSV')",
)
azure_query(
node, f"INSERT INTO test_write_connection_string_2 VALUES (1, 'a')"
)
azure_query(node, f"INSERT INTO test_write_connection_string_2 VALUES (1, 'a')")
print(get_azure_file_content("test_simple_write_2.csv", port))
assert get_azure_file_content("test_simple_write_2.csv", port) == '1,"a"\n'
backup_destination = f"AzureBlobStorage(azure_conf2, 'test_simple_write_nc_backup_2.csv')"
backup_destination = (
f"AzureBlobStorage(azure_conf2, 'test_simple_write_nc_backup_2.csv')"
)
azure_query(
node,
f"BACKUP TABLE test_write_connection_string_2 TO {backup_destination}",