Sync slaves after creating tables in rwsplit_readonly

The test should synchronize the replication to avoid replication lag from
breaking the tests.
This commit is contained in:
Markus Mäkelä 2018-03-15 23:19:11 +02:00
parent 07cca088c9
commit dad8e5da59
No known key found for this signature in database
GPG Key ID: 72D48FCE664F7B19

View File

@ -259,10 +259,14 @@ int main(int argc, char *argv[])
/** Prepare for tests */
Test->stop_timeout();
Test->maxscales->connect_maxscale(0);
execute_query_silent(Test->maxscales->conn_rwsplit[0], "DROP TABLE IF EXISTS test.readonly\n");
execute_query_silent(Test->maxscales->conn_rwsplit[0], "CREATE TABLE test.readonly(id int)\n");
execute_query_silent(Test->maxscales->conn_rwsplit[0], "DROP TABLE IF EXISTS test.readonly");
execute_query_silent(Test->maxscales->conn_rwsplit[0], "CREATE TABLE test.readonly(id int)");
Test->maxscales->close_maxscale_connections(0);
Test->repl->connect();
Test->repl->sync_slaves();
Test->repl->disconnect();
/** Basic tests */
test_basic(Test);