Clean up setup_binlog_gtid
Removed redundant operations and cleaned up unused code.
This commit is contained in:

committed by
Johan Wikman

parent
8be898d1d3
commit
16530b4a97
@ -1,48 +1,23 @@
|
|||||||
/**
|
/**
|
||||||
* @file setup_binlog_gtid.cpp test of simple binlog router setup
|
* @file setup_binlog_gtid.cpp - Basic GTID testing of binlogrouter
|
||||||
|
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
#include <iostream>
|
|
||||||
#include "testconnections.h"
|
#include "testconnections.h"
|
||||||
#include "maxadmin_operations.h"
|
|
||||||
#include "sql_t1.h"
|
|
||||||
|
|
||||||
#include "test_binlog_fnc.h"
|
#include "test_binlog_fnc.h"
|
||||||
|
|
||||||
|
|
||||||
int main(int argc, char *argv[])
|
int main(int argc, char *argv[])
|
||||||
{
|
{
|
||||||
|
|
||||||
TestConnections * Test = new TestConnections(argc, argv);
|
TestConnections test(argc, argv);
|
||||||
Test->set_timeout(3000);
|
test.binlog_master_gtid = true;
|
||||||
int options_set = 3;
|
test.binlog_slave_gtid = true;
|
||||||
if (Test->smoke)
|
|
||||||
{
|
|
||||||
options_set = 1;
|
|
||||||
}
|
|
||||||
|
|
||||||
Test->repl->connect();
|
test.start_binlog();
|
||||||
execute_query(Test->repl->nodes[0], (char *) "DROP TABLE IF EXISTS t1;");
|
test_binlog(&test);
|
||||||
Test->repl->close_connections();
|
|
||||||
sleep(5);
|
|
||||||
|
|
||||||
Test->binlog_master_gtid = true;
|
test.check_log_err("SET NAMES utf8mb4", false);
|
||||||
Test->binlog_slave_gtid = true;
|
test.check_log_err("set autocommit=1", false);
|
||||||
// for (int option = 0; option < options_set; option++)
|
test.check_log_err("select USER()", false);
|
||||||
//{
|
|
||||||
// Test->binlog_cmd_option = option;
|
|
||||||
Test->start_binlog();
|
|
||||||
test_binlog(Test);
|
|
||||||
//}
|
|
||||||
|
|
||||||
Test->check_log_err("SET NAMES utf8mb4", false);
|
return test.global_result;
|
||||||
Test->check_log_err("set autocommit=1", false);
|
|
||||||
Test->check_log_err("select USER()", false);
|
|
||||||
|
|
||||||
int rval = Test->global_result;
|
|
||||||
delete Test;
|
|
||||||
return rval;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user