MXS-2220 Change server name to constant string
This commit is contained in:
@ -79,7 +79,8 @@ int test(bool success, const char* zHost, const char* zUser, const char* zPasswo
|
||||
MXS_CONFIG* config = config_get_global_options();
|
||||
config->local_address = const_cast<char*>(zAddress);
|
||||
|
||||
Server server;
|
||||
Server* pServer = Server::create_test_server();
|
||||
Server& server = *pServer;
|
||||
strcpy(server.address, zHost);
|
||||
server.port = 3306;
|
||||
|
||||
|
||||
@ -112,7 +112,7 @@ bool test_load_config(const char* input, SERVER* server)
|
||||
MXS_CONFIG_PARAMETER* param = obj->parameters;
|
||||
config_add_defaults(obj, config_server_params);
|
||||
|
||||
TEST(strcmp(obj->object, server->name) == 0, "Server names differ");
|
||||
TEST(strcmp(obj->object, server->name()) == 0, "Server names differ");
|
||||
TEST(strcmp(server->address, config_get_param(param, "address")->value) == 0,
|
||||
"Server addresses differ");
|
||||
TEST(strcmp(server->protocol, config_get_param(param, "protocol")->value) == 0,
|
||||
|
||||
Reference in New Issue
Block a user