MXS-2900 maxtest includes cleanup, part 3

This commit is contained in:
Esa Korhonen 2020-06-16 16:47:51 +03:00
parent 238725b72e
commit 680ba80870
274 changed files with 323 additions and 330 deletions

View File

@ -19,13 +19,8 @@ set(TEST_DEFINITIONS "" CACHE INTERNAL "")
include(utilities.cmake)
include_directories(${CMAKE_CURRENT_SOURCE_DIR})
include_directories(${CMAKE_CURRENT_BINARY_DIR})
include_directories(${CMAKE_SOURCE_DIR}/connectors/cdc-connector)
include_directories(${CMAKE_BINARY_DIR})
# Include the CDC connector headers
include_directories(${CMAKE_SOURCE_DIR}/../connectors/cdc-connector/)
include_directories(maxtest/include/maxtest)
include_directories(${CMAKE_SOURCE_DIR}/connectors/cdc-connector)
include_directories(maxtest/include)
# Tool used to check backend state

View File

@ -2,7 +2,7 @@
* Test runtime modification of router options
*/
#include "testconnections.h"
#include <maxtest/testconnections.h>
#include <vector>
#include <iostream>
#include <functional>

View File

@ -2,7 +2,7 @@
* @file avro_alter.cpp Test ALTER TABLE handling of avrorouter
*/
#include "testconnections.h"
#include <maxtest/testconnections.h>
#include <jansson.h>
#include <sstream>
#include <iostream>

View File

@ -4,7 +4,7 @@
* MaxScale should not crash
*/
#include "testconnections.h"
#include <maxtest/testconnections.h>
int main(int argc, char** argv)
{

View File

@ -1,7 +1,7 @@
/**
* Test binary protocol prepared statement routing
*/
#include "testconnections.h"
#include <maxtest/testconnections.h>
int main(int argc, char** argv)
{

View File

@ -1,7 +1,7 @@
/**
* Test that binary protocol cursors work as expected
*/
#include "testconnections.h"
#include <maxtest/testconnections.h>
#include <iostream>
using std::cout;

View File

@ -11,7 +11,7 @@
* - check data on all nodes
*/
#include "testconnections.h"
#include <maxtest/testconnections.h>
#include "binlog_change_master_common.cpp"
int main(int argc, char* argv[])

View File

@ -1,4 +1,4 @@
#include "testconnections.h"
#include <maxtest/testconnections.h>
#include <functional>
void run_test(TestConnections& test, std::function<void(MYSQL*)> cb)

View File

@ -2,7 +2,7 @@
* The GTID version of binlog_change_master
*/
#include "testconnections.h"
#include <maxtest/testconnections.h>
#include "binlog_change_master_common.cpp"
int main(int argc, char* argv[])

View File

@ -5,9 +5,7 @@
#include <iostream>
#include "testconnections.h"
#include "maxadmin_operations.h"
#include "sql_t1.h"
#include <maxtest/testconnections.h>
int main(int argc, char* argv[])
{

View File

@ -5,7 +5,7 @@
* - try to connect using RWSplit. First and third are expected to fail, second should succeed.
*/
#include "testconnections.h"
#include <maxtest/testconnections.h>
int main(int argc, char* argv[])
{

View File

@ -145,7 +145,7 @@
#include <iostream>
#include <unistd.h>
#include "testconnections.h"
#include <maxtest/testconnections.h>
using namespace std;

View File

@ -50,7 +50,7 @@
#include <iostream>
#include <unistd.h>
#include "testconnections.h"
#include <maxtest/testconnections.h>
using namespace std;

View File

@ -30,7 +30,7 @@
#include <iostream>
#include <unistd.h>
#include "testconnections.h"
#include <maxtest/testconnections.h>
using namespace std;

View File

@ -67,8 +67,8 @@
#include <iostream>
#include "testconnections.h"
#include "sql_t1.h"
#include <maxtest/testconnections.h>
#include <maxtest/sql_t1.h>
using namespace std;

View File

@ -126,8 +126,8 @@
#include <iostream>
#include "testconnections.h"
#include "sql_t1.h"
#include <maxtest/testconnections.h>
#include <maxtest/sql_t1.h>
using namespace std;

View File

@ -18,7 +18,7 @@
// also relates to bug594
// all slaves in MaxScale config have wrong IP
#include "testconnections.h"
#include <maxtest/testconnections.h>
int main(int argc, char* argv[])
{

View File

@ -53,7 +53,7 @@
#include <iostream>
#include "testconnections.h"
#include <maxtest/testconnections.h>
int main(int argc, char* argv[])
{

View File

@ -115,7 +115,7 @@
#include <iostream>
#include <unistd.h>
#include "testconnections.h"
#include <maxtest/testconnections.h>
using namespace std;

View File

@ -13,7 +13,7 @@
#include <iostream>
#include <unistd.h>
#include "testconnections.h"
#include <maxtest/testconnections.h>
using namespace std;

View File

@ -65,7 +65,7 @@
#include <iostream>
#include <unistd.h>
#include "testconnections.h"
#include <maxtest/testconnections.h>
using namespace std;

View File

@ -87,7 +87,7 @@
#include <iostream>
#include "testconnections.h"
#include <maxtest/testconnections.h>
int main(int argc, char* argv[])
{

View File

@ -46,7 +46,7 @@
#include <iostream>
#include "testconnections.h"
#include <maxtest/testconnections.h>
using namespace std;

View File

@ -235,7 +235,7 @@
#include <iostream>
#include <unistd.h>
#include "testconnections.h"
#include <maxtest/testconnections.h>
using namespace std;

View File

@ -2,7 +2,7 @@
* Check that old-style passwords are detected
*/
#include "testconnections.h"
#include <maxtest/testconnections.h>
int main(int argc, char* argv[])
{

View File

@ -46,7 +46,7 @@
#include <iostream>
#include "testconnections.h"
#include <maxtest/testconnections.h>
int main(int argc, char* argv[])
{

View File

@ -57,8 +57,8 @@
*/
#include "testconnections.h"
#include "maxadmin_operations.h"
#include <maxtest/testconnections.h>
#include <maxtest/maxadmin_operations.h>
int main(int argc, char* argv[])
{

View File

@ -23,7 +23,7 @@
#include <iostream>
#include "testconnections.h"
#include <maxtest/testconnections.h>
int main(int argc, char* argv[])
{

View File

@ -9,8 +9,8 @@
* - Sleep and check if Maxscale is alive
*/
#include "testconnections.h"
#include "maxadmin_operations.h"
#include <maxtest/testconnections.h>
#include <maxtest/maxadmin_operations.h>
int main(int argc, char* argv[])
{

View File

@ -6,7 +6,7 @@
* - An error should be logged about the failed branch session
*/
#include "testconnections.h"
#include <maxtest/testconnections.h>
int main(int argc, char* argv[])
{

View File

@ -8,8 +8,8 @@
* - Check that only new style object names in maxadmin commands are accepted
*/
#include "testconnections.h"
#include "maxadmin_operations.h"
#include <maxtest/testconnections.h>
#include <maxtest/maxadmin_operations.h>
int main(int argc, char* argv[])
{

View File

@ -273,8 +273,8 @@
#include <iostream>
#include "testconnections.h"
#include "maxadmin_operations.h"
#include <maxtest/testconnections.h>
#include <maxtest/maxadmin_operations.h>
int main(int argc, char* argv[])
{

View File

@ -60,7 +60,7 @@
#include <iostream>
#include "testconnections.h"
#include <maxtest/testconnections.h>
int main(int argc, char* argv[])
{

View File

@ -41,7 +41,7 @@
#include <iostream>
#include "testconnections.h"
#include <maxtest/testconnections.h>
int main(int argc, char* argv[])
{

View File

@ -5,7 +5,7 @@
* https://mariadb.com/kb/en/mariadb/bulk-insert-column-wise-binding/
*/
#include "testconnections.h"
#include <maxtest/testconnections.h>
static int show_mysql_error(MYSQL* mysql)
{

View File

@ -14,7 +14,7 @@
#include <iostream>
#include <string>
#include <vector>
#include "testconnections.h"
#include <maxtest/testconnections.h>
using namespace std;

View File

@ -14,7 +14,7 @@
#include <iostream>
#include <string>
#include <vector>
#include "testconnections.h"
#include <maxtest/testconnections.h>
using namespace std;

View File

@ -23,7 +23,7 @@
#include <iostream>
#include <unistd.h>
#include "testconnections.h"
#include <maxtest/testconnections.h>
static int master_id;

View File

@ -2,7 +2,7 @@
* Test global mode for the CCRFilter
*/
#include "testconnections.h"
#include <maxtest/testconnections.h>
int main(int argc, char* argv[])
{

View File

@ -2,7 +2,7 @@
* @file cdc_connect.cpp Test the CDC protocol
*/
#include "testconnections.h"
#include <maxtest/testconnections.h>
#include <cdc_connector.h>
#include "cdc_result.h"
#include <iostream>

View File

@ -1,5 +1,5 @@
#include <iostream>
#include "testconnections.h"
#include <maxtest/testconnections.h>
using namespace std;

View File

@ -7,8 +7,8 @@
*/
#include <iostream>
#include "testconnections.h"
#include "sql_t1.h"
#include <maxtest/testconnections.h>
#include <maxtest/sql_t1.h>
using namespace std;

View File

@ -12,7 +12,7 @@
* - try INSERT again expecting success (user should not be changed)
*/
#include "testconnections.h"
#include <maxtest/testconnections.h>
void run_test(TestConnections& test, MYSQL* conn)
{

View File

@ -4,7 +4,7 @@
#include <iostream>
#include "testconnections.h"
#include <maxtest/testconnections.h>
int main(int argc, char *argv[])
{

View File

@ -19,7 +19,7 @@
* See Clustrix_nodes.h for details about configiration
*/
#include "testconnections.h"
#include <maxtest/testconnections.h>
int main(int argc, char* argv[])
{

View File

@ -2,7 +2,7 @@
* Test 10.1 compound statements
*/
#include "testconnections.h"
#include <maxtest/testconnections.h>
int main(int argc, char** argv)
{

View File

@ -5,7 +5,7 @@
#include <iostream>
#include <unistd.h>
#include "testconnections.h"
#include <maxtest/testconnections.h>
using std::string;

View File

@ -2,8 +2,8 @@
* @file connect_to_nonexisting_db.cpp Tries to connect to non existing DB, expects no crash
*/
#include "testconnections.h"
#include "sql_t1.h"
#include <maxtest/testconnections.h>
#include <maxtest/sql_t1.h>
bool try_connect(TestConnections& test)
{

View File

@ -6,7 +6,7 @@
* - create max num of connections and check tha N+1 connection fails
*/
#include "testconnections.h"
#include <maxtest/testconnections.h>
void check_with_wrong_pw(int router, int max_conn, TestConnections& test);
void check_max_conn(int router, int max_conn, TestConnections& test);

View File

@ -2,7 +2,7 @@
* Double-close on bad session command result
*/
#include "testconnections.h"
#include <maxtest/testconnections.h>
void run_test(TestConnections& test)
{

View File

@ -2,7 +2,7 @@
* MXS-2146: Test case for csmon
*/
#include "testconnections.h"
#include <maxtest/testconnections.h>
int main(int argc, char* argv[])
{

View File

@ -4,7 +4,7 @@
*/
#include <iostream>
#include "testconnections.h"
#include <maxtest/testconnections.h>
/** Remove old keys and create a new one */
int create_key(TestConnections* test)

View File

@ -6,7 +6,7 @@
* - repeat for RWSplit, ReadConn
*/
#include "testconnections.h"
#include <maxtest/testconnections.h>
#include <iostream>
#include <algorithm>

View File

@ -1,4 +1,4 @@
#include "testconnections.h"
#include <maxtest/testconnections.h>
int inserts = 0;
bool interactive = false;

View File

@ -2,7 +2,7 @@
* Test false server state changes when manually clearing master bit
*/
#include "testconnections.h"
#include <maxtest/testconnections.h>
int main(int argc, char* argv[])
{

View File

@ -18,10 +18,10 @@
#include <iostream>
#include <ctime>
#include "testconnections.h"
#include "maxadmin_operations.h"
#include "sql_t1.h"
#include "fw_copy_rules.h"
#include <maxtest/testconnections.h>
#include <maxtest/maxadmin_operations.h>
#include <maxtest/sql_t1.h>
#include <maxtest/fw_copy_rules.h>
int main(int argc, char* argv[])
{

View File

@ -17,10 +17,10 @@
#include <iostream>
#include <ctime>
#include "testconnections.h"
#include "maxadmin_operations.h"
#include "sql_t1.h"
#include "fw_copy_rules.h"
#include <maxtest/testconnections.h>
#include <maxtest/maxadmin_operations.h>
#include <maxtest/sql_t1.h>
#include <maxtest/fw_copy_rules.h>
int read_and_execute_queries(TestConnections* Test, const char* filename, int expected)
{

View File

@ -9,8 +9,8 @@
#include <iostream>
#include <unistd.h>
#include "testconnections.h"
#include "fw_copy_rules.h"
#include <maxtest/testconnections.h>
#include <maxtest/fw_copy_rules.h>
int main(int argc, char** argv)
{

View File

@ -4,8 +4,8 @@
* Check that COM_PING is allowed with `action=allow`
*/
#include "testconnections.h"
#include "fw_copy_rules.h"
#include <maxtest/testconnections.h>
#include <maxtest/fw_copy_rules.h>
const char* rules = "rule test1 deny regex '.*'\n"
"users %@% match any rules test1\n";

View File

@ -4,8 +4,8 @@
* Check if duplicate rules are detected.
*/
#include "testconnections.h"
#include "fw_copy_rules.h"
#include <maxtest/testconnections.h>
#include <maxtest/fw_copy_rules.h>
const char* rules = "rule test1 deny no_where_clause\n"
"rule test1 deny columns a b c\n"

View File

@ -7,8 +7,8 @@
#include <iostream>
#include <unistd.h>
#include "testconnections.h"
#include "fw_copy_rules.h"
#include <maxtest/testconnections.h>
#include <maxtest/fw_copy_rules.h>
int main(int argc, char** argv)
{

View File

@ -5,8 +5,8 @@
* properly handled.
*/
#include "testconnections.h"
#include "fw_copy_rules.h"
#include <maxtest/testconnections.h>
#include <maxtest/fw_copy_rules.h>
const char* rules = "rule test1 deny columns c on_queries select\n"
"users %@% match any rules test1\n";

View File

@ -5,10 +5,10 @@
#include <iostream>
#include <ctime>
#include "testconnections.h"
#include "maxadmin_operations.h"
#include "sql_t1.h"
#include "fw_copy_rules.h"
#include <maxtest/testconnections.h>
#include <maxtest/maxadmin_operations.h>
#include <maxtest/sql_t1.h>
#include <maxtest/fw_copy_rules.h>
int main(int argc, char* argv[])
{

View File

@ -4,8 +4,8 @@
* Check that COM_PING is allowed with `action=allow`
*/
#include "testconnections.h"
#include "fw_copy_rules.h"
#include <maxtest/testconnections.h>
#include <maxtest/fw_copy_rules.h>
#include <fstream>

View File

@ -10,8 +10,8 @@
#include <iostream>
#include <unistd.h>
#include <linux/limits.h>
#include "testconnections.h"
#include "fw_copy_rules.h"
#include <maxtest/testconnections.h>
#include <maxtest/fw_copy_rules.h>
const char* temp_rules = "rules_tmp.txt";

View File

@ -13,7 +13,7 @@
#include <iostream>
#include "testconnections.h"
#include <maxtest/testconnections.h>
using namespace std;

View File

@ -7,7 +7,7 @@
#include <iostream>
#include "testconnections.h"
#include <maxtest/testconnections.h>
int main(int argc, char* argv[])
{

View File

@ -9,7 +9,7 @@
*/
#include "testconnections.h"
#include <maxtest/testconnections.h>
int main(int argc, char* argv[])
{

View File

@ -2,7 +2,7 @@
* Test KILL QUERY functionality
*/
#include "testconnections.h"
#include <maxtest/testconnections.h>
int main(int argc, char* argv[])
{

View File

@ -11,7 +11,7 @@
* Public License.
*/
#include "testconnections.h"
#include <maxtest/testconnections.h>
#include <algorithm>
#include <iostream>
#include <iterator>

View File

@ -8,7 +8,7 @@
*/
#include "testconnections.h"
#include <maxtest/testconnections.h>
#include "sysbench_commands.h"
int main(int argc, char* argv[])

View File

@ -6,8 +6,8 @@
*/
#include "testconnections.h"
#include "sql_t1.h"
#include <maxtest/testconnections.h>
#include <maxtest/sql_t1.h>
typedef void * FUNC(void * ptr);

View File

@ -6,8 +6,8 @@
#include <iostream>
#include "testconnections.h"
#include "sql_t1.h"
#include <maxtest/testconnections.h>
#include <maxtest/sql_t1.h>
int main(int argc, char* argv[])
{

View File

@ -11,7 +11,7 @@
#include <iostream>
#include <sstream>
#include "testconnections.h"
#include <maxtest/testconnections.h>
#include "fail_switch_rejoin_common.cpp"
using std::stringstream;

View File

@ -11,7 +11,7 @@
* Public License.
*/
#include "testconnections.h"
#include <maxtest/testconnections.h>
#include <iostream>
#include <maxbase/format.hh>

View File

@ -1,7 +1,7 @@
/**
* Test monitoring and failover with ignore_external_masters=true
*/
#include "testconnections.h"
#include <maxtest/testconnections.h>
#include "fail_switch_rejoin_common.cpp"
#include <atomic>
#include <thread>

View File

@ -11,7 +11,7 @@
* Public License.
*/
#include "testconnections.h"
#include <maxtest/testconnections.h>
#include "failover_common.cpp"
#include <string>

View File

@ -11,7 +11,7 @@
* Public License.
*/
#include "testconnections.h"
#include <maxtest/testconnections.h>
#include "fail_switch_rejoin_common.cpp"
#include <iostream>
#include <string>

View File

@ -11,7 +11,7 @@
* Public License.
*/
#include "testconnections.h"
#include <maxtest/testconnections.h>
#include "failover_common.cpp"
int main(int argc, char** argv)

View File

@ -11,7 +11,7 @@
* Public License.
*/
#include "testconnections.h"
#include <maxtest/testconnections.h>
#include <exception>
#include <iostream>
#include <sstream>

View File

@ -13,7 +13,7 @@
// MXS-2652: https://jira.mariadb.org/browse/MXS-2652
#include "testconnections.h"
#include <maxtest/testconnections.h>
#include "fail_switch_rejoin_common.cpp"
using std::string;

View File

@ -11,7 +11,7 @@
* Public License.
*/
#include "testconnections.h"
#include <maxtest/testconnections.h>
#include "fail_switch_rejoin_common.cpp"
#include <iostream>
#include <string>

View File

@ -15,7 +15,7 @@
#include <iterator>
#include <string>
#include <sstream>
#include "testconnections.h"
#include <maxtest/testconnections.h>
using std::cerr;
using std::cout;

View File

@ -14,7 +14,7 @@
#include <iostream>
#include <string>
#include <sstream>
#include "testconnections.h"
#include <maxtest/testconnections.h>
using std::cerr;
using std::cout;

View File

@ -15,7 +15,7 @@
#include <iterator>
#include <string>
#include <sstream>
#include "testconnections.h"
#include <maxtest/testconnections.h>
using std::cerr;
using std::cout;

View File

@ -18,7 +18,7 @@
#include <thread>
#include <vector>
#include <random>
#include "testconnections.h"
#include <maxtest/testconnections.h>
#include "fail_switch_rejoin_common.cpp"
using namespace std;

View File

@ -21,9 +21,9 @@
#include <iostream>
#include <string>
#include <set>
#include "testconnections.h"
#include "maxadmin_operations.h"
#include "sql_t1.h"
#include <maxtest/testconnections.h>
#include <maxtest/maxadmin_operations.h>
#include <maxtest/sql_t1.h>
#include <jansson.h>
#include <maxbase/string.hh>

View File

@ -14,7 +14,7 @@
#include <iostream>
#include <vector>
#include "testconnections.h"
#include <maxtest/testconnections.h>
#include "fail_switch_rejoin_common.cpp"
using std::string;

View File

@ -15,7 +15,7 @@
#include <iostream>
#include <iterator>
#include "testconnections.h"
#include <maxtest/testconnections.h>
#include "fail_switch_rejoin_common.cpp"
using std::string;

View File

@ -13,7 +13,7 @@
#include <vector>
#include "testconnections.h"
#include <maxtest/testconnections.h>
#include "fail_switch_rejoin_common.cpp"
#include <iostream>

View File

@ -11,7 +11,7 @@
* Public License.
*/
#include "testconnections.h"
#include <maxtest/testconnections.h>
#include "fail_switch_rejoin_common.cpp"
#include <iostream>
#include <string>

View File

@ -15,7 +15,7 @@
#include <iterator>
#include <string>
#include <sstream>
#include "testconnections.h"
#include <maxtest/testconnections.h>
using std::cerr;
using std::cout;

View File

@ -11,7 +11,7 @@
* Public License.
*/
#include "testconnections.h"
#include <maxtest/testconnections.h>
#include "fail_switch_rejoin_common.cpp"
#include <iostream>
#include <string>

View File

@ -15,7 +15,7 @@
#include <iterator>
#include <string>
#include <sstream>
#include "testconnections.h"
#include <maxtest/testconnections.h>
using std::cerr;
using std::cout;

View File

@ -18,7 +18,7 @@
#include <thread>
#include <vector>
#include <random>
#include "testconnections.h"
#include <maxtest/testconnections.h>
#include "fail_switch_rejoin_common.cpp"
using namespace std;

View File

@ -4,7 +4,7 @@
* Testing of master failure verification
*/
#include "testconnections.h"
#include <maxtest/testconnections.h>
int main(int argc, char* argv[])
{

View File

@ -12,7 +12,7 @@
*/
#include <iostream>
#include "testconnections.h"
#include <maxtest/testconnections.h>
using namespace std;

View File

@ -7,7 +7,7 @@
* - close all connections
*/
#include "testconnections.h"
#include <maxtest/testconnections.h>
#define CONNECTIONS 21
#define ITER 25

View File

@ -2,7 +2,7 @@
* Minimal MaxCtrl sanity check
*/
#include "testconnections.h"
#include <maxtest/testconnections.h>
int main(int argc, char** argv)
{

View File

@ -2,7 +2,7 @@
* Test MaxInfo with the SQL interface
*/
#include "testconnections.h"
#include <maxtest/testconnections.h>
#include <string>
#include <thread>
#include <vector>

Some files were not shown because too many files have changed in this diff Show More