Debian Codegraph @

mysql-test/suite/innodb/t/truncate_crash.test

raw
1 --source include/have_innodb.inc
2 --source include/have_debug.inc
3 --source include/have_debug_sync.inc
4 --source include/not_embedded.inc
5
6 FLUSH TABLES;
7 CREATE TABLE t1 (a INT PRIMARY KEY) ENGINE=InnoDB STATS_PERSISTENT=0;
8 INSERT INTO t1 VALUES (1),(2);
9
10 connect (wait,localhost,root,,test);
11 SET DEBUG_SYNC='before_trx_state_committed_in_memory SIGNAL c WAIT_FOR ever';
12 send TRUNCATE TABLE t1;
13
14 connection default;
15 SET DEBUG_SYNC='now WAIT_FOR c';
16 --let $shutdown_timeout=0
17 --source include/restart_mysqld.inc
18 disconnect wait;
19
20 --source include/wait_all_purged.inc
21
22 --replace_result 2 0
23 SELECT COUNT(*) FROM t1;
24 TRUNCATE TABLE t1;
25 DROP TABLE t1;
26