MCPcopy Create free account
hub / github.com/MaterializeInc/materialize / sql_expect_crash

Function sql_expect_crash

test/cloudtest/test_compute.py:65–72  ·  view source on GitHub ↗
(sql: str)

Source from the content-addressed store, hash-verified

63 mz.set_environmentd_failpoints(failpoint)
64
65 def sql_expect_crash(sql: str) -> None:
66 # We expect executing `sql` will crash environmentd. To ensure it is actually `sql`
67 # wait until the SQL interface is available.
68 mz.wait_for_sql()
69 try:
70 mz.environmentd.sql(sql)
71 except InterfaceError as e:
72 LOGGER.error(f"Expected SQL error: {e}")
73
74 mz.environmentd.sql(
75 "CREATE CLUSTER shutdown1 REPLICAS (shutdown_replica1 (SIZE 'scale=1,workers=1'), shutdown_replica2 (SIZE 'scale=1,workers=1'))"

Callers 1

test_cluster_shutdownFunction · 0.85

Calls 3

wait_for_sqlMethod · 0.80
sqlMethod · 0.45
errorMethod · 0.45

Tested by

no test coverage detected