MXS-2243 System tests brings VMs by themselves (#193)

maxscale-system-test changed in order to control test environment by itself.
Every test checks which machines are running, compare with list of needed machines
and start new VMs is they are missing in the running machines list.
Tests are executiong MDBCI commands, MDBCI executable should be in the PATH
This commit is contained in:
Timofey Turenko
2019-04-02 13:27:34 +03:00
committed by GitHub
parent 868ae4456c
commit cd732ac14f
78 changed files with 1506 additions and 1676 deletions

View File

@ -1,11 +1,16 @@
#ifndef MAXSCALES_H
#define MAXSCALES_H
#pragma once
#include <string>
#include "nodes.h"
#include "mariadb_func.h"
#include "mariadb_nodes.h"
class Maxscales : public Nodes
#define DEFAULT_MAXSCALE_CNF "/etc/maxscale.cnf"
#define DEFAULT_MAXSCALE_LOG_DIR "/var/log/maxscale/"
#define DEFAULT_MAXSCALE_BINLOG_DIR "/var/lib/maxscale/Binlog_Service/"
#define DEFAULT_MAXADMIN_PASSWORD "mariadb"
class Maxscales: public Nodes
{
public:
enum service
@ -15,7 +20,9 @@ public:
READCONN_SLAVE
};
Maxscales(const char* pref, const char* test_cwd, bool verbose, bool use_valgrind);
Maxscales(const char *pref, const char *test_cwd, bool verbose, bool use_valgrind,
std::__cxx11::string network_config);
int read_env();
/**
@ -76,29 +83,28 @@ public:
/**
* @brief maxadmin_Password Password to access Maxadmin tool
*/
char maxadmin_password[256][256];
char * maxadmin_password[256];
/**
* @brief maxscale_cnf full name of Maxscale configuration file
*/
char maxscale_cnf[256][4096];
* @brief maxscale_cnf full name of Maxscale configuration file
*/
char * maxscale_cnf[256];
/**
* @brief maxscale_log_dir name of log files directory
*/
char maxscale_log_dir[256][4096];
* @brief maxscale_log_dir name of log files directory
*/
char * maxscale_log_dir[256];
/**
* @brief maxscale_lbinog_dir name of binlog files (for binlog router) directory
*/
char maxscale_binlog_dir[256][4096];
* @brief maxscale_lbinog_dir name of binlog files (for binlog router) directory
*/
char * maxscale_binlog_dir[256];
/**
* @brief N_ports Default number of routers
*/
int N_ports[256];
/**
* @brief test_dir path to test application
*/
@ -252,10 +258,8 @@ public:
/**
* @brief alias for restart_maxscale
*/
int start_maxscale(int m = 0)
{
return restart_maxscale(m);
}
int start_maxscale(int m = 0);
int start(int m = 0)
{
return start_maxscale(m);
@ -330,7 +334,4 @@ public:
*/
int valgring_log_num;
};
#endif // MAXSCALES_H