Debian Codegraph @

mysql-test/suite/sysschema/t/mysqldump.test

raw
1 -- source include/no_valgrind_without_big.inc
2
3 # Dump all databases
4 --exec $MYSQL_DUMP -uroot --all-databases > $MYSQLTEST_VARDIR/tmp/bug20902791.sql
5
6 # Save a copy of the user/tables_priv tables, to restore later
7 # Otherwise the final mysql_upgrade will REPLACE and update timestamps etc.
8 --let $backup=1
9 --source include/backup_tables_priv_and_users.inc
10
11 # Remove the sys schema
12 DROP DATABASE sys;
13
14 # Reload the dump
15 --exec $MYSQL < $MYSQLTEST_VARDIR/tmp/bug20902791.sql
16
17 # The sys schema should not exist
18 SHOW DATABASES;
19
20 # Finally reload the sys schema to return to normal
21 --let $restart_parameters = restart:--upgrade=FORCE
22 --let $wait_counter= 10000
23 --source include/restart_mysqld.inc
24
25 SHOW DATABASES;
26
27 # Restore the saved contents of mysql.user and mysql.tables_priv
28 --let $restore=1
29 --source include/backup_tables_priv_and_users.inc
30
31 FLUSH PRIVILEGES;
32 --source include/force_restart.inc