Skip to content

Commit 075c026

Browse files
committed
These queries need to be run in the same session
1 parent 8d0824f commit 075c026

File tree

1 file changed

+7
-5
lines changed
  • tests/integration/test_restart_server

1 file changed

+7
-5
lines changed

tests/integration/test_restart_server/test.py

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -24,11 +24,13 @@ def test_drop_memory_database():
2424

2525
def test_flushes_async_insert_queue():
2626
node.query(
27-
"CREATE TABLE flush_test (a String, b UInt64) ENGINE = MergeTree ORDER BY a;"
27+
"""
28+
CREATE TABLE flush_test (a String, b UInt64) ENGINE = MergeTree ORDER BY a;
29+
SET async_insert = 1;
30+
SET wait_for_async_insert = 0;
31+
SET async_insert_busy_timeout_ms = 1000000;
32+
INSERT INTO flush_test VALUES ('world', 23456);
33+
"""
2834
)
29-
node.query("SET async_insert = 1;")
30-
node.query("SET wait_for_async_insert = 0;")
31-
node.query("SET async_insert_busy_timeout_ms = 1000000;")
32-
node.query("INSERT INTO flush_test VALUES ('world', 23456);")
3335
node.restart_clickhouse()
3436
assert node.query("SELECT * FROM flush_test") == "world\t23456\n"

0 commit comments

Comments
 (0)