2024-06-06 05:42:07 +00:00
|
|
|
from helpers.cluster import ClickHouseCluster
|
|
|
|
|
|
|
|
|
|
|
|
def test_startup_scripts():
|
|
|
|
cluster = ClickHouseCluster(__file__)
|
|
|
|
|
|
|
|
node = cluster.add_instance(
|
|
|
|
"node",
|
2024-06-21 16:10:49 +00:00
|
|
|
main_configs=[
|
|
|
|
"configs/config.d/query_log.xml",
|
|
|
|
"configs/config.d/startup_scripts.xml",
|
|
|
|
],
|
2024-06-06 05:42:07 +00:00
|
|
|
with_zookeeper=False,
|
|
|
|
)
|
|
|
|
|
|
|
|
try:
|
|
|
|
cluster.start()
|
|
|
|
assert node.query("SHOW TABLES") == "TestTable\n"
|
2024-10-03 11:28:29 +00:00
|
|
|
assert (
|
|
|
|
node.query(
|
|
|
|
"SELECT value, changed FROM system.settings WHERE name = 'skip_unavailable_shards'"
|
|
|
|
)
|
|
|
|
== "0\t0\n"
|
|
|
|
)
|
2024-06-06 05:42:07 +00:00
|
|
|
|
|
|
|
finally:
|
|
|
|
cluster.shutdown()
|