to 15357_MaterializeMySQL_support_drop_mulit_table-fix style-black

This commit is contained in:
zzsmdfj 2022-11-21 11:48:57 +08:00
parent e177927efb
commit a0f391745d
2 changed files with 5 additions and 3 deletions

View File

@ -2202,8 +2202,9 @@ def dropddl(clickhouse_node, mysql_node, mysql_host):
f"CREATE DATABASE {db} ENGINE = MaterializeMySQL('{mysql_host}:3306', '{db}', 'root', 'clickhouse')"
)
check_query(
clickhouse_node, f"SELECT count() FROM system.tables where database = '{db}' FORMAT TSV",
"4\n"
clickhouse_node,
f"SELECT count() FROM system.tables where database = '{db}' FORMAT TSV",
"4\n",
)
check_query(clickhouse_node, f"SELECT * FROM {db}.t1 FORMAT TSV", "1\t1\n")
mysql_node.query(f"DROP EVENT IF EXISTS {db}.event_name")
@ -2220,7 +2221,7 @@ def dropddl(clickhouse_node, mysql_node, mysql_host):
check_query(
clickhouse_node,
f"SELECT name FROM system.tables where database = '{db}' FORMAT TSV",
"t1\nt2\n"
"t1\nt2\n",
)
mysql_node.query(f"DROP DATABASE {db}")
clickhouse_node.query(f"DROP DATABASE {db}")

View File

@ -517,6 +517,7 @@ def test_savepoint_query(
materialize_with_ddl.savepoint(clickhouse_node, started_mysql_8_0, "mysql80")
materialize_with_ddl.savepoint(clickhouse_node, started_mysql_5_7, "mysql57")
def test_materialized_database_mysql_drop_ddl(
started_cluster, started_mysql_8_0, started_mysql_5_7, clickhouse_node
):