MXS-2417: Add test case

This commit is contained in:
Markus Mäkelä 2019-04-04 08:59:28 +03:00
parent b08d4e37b5
commit 556c83f83a
No known key found for this signature in database
GPG Key ID: 72D48FCE664F7B19
3 changed files with 30 additions and 0 deletions

View File

@ -939,6 +939,9 @@ add_test_executable(mxs2300_history_pruning.cpp mxs2300_history_pruning mxs2300_
# MXS-2326: Routing hints aren't cloned in gwbuf_clone
add_test_executable(mxs2326_hint_clone.cpp mxs2326_hint_clone mxs2326_hint_clone LABELS readwritesplit REPL_BACKEND)
# MXS-2417: Ignore persisted configs with load_persisted_configs=false
add_test_executable(mxs2417_ignore_persisted_cnf.cpp mxs2417_ignore_persisted_cnf mxs2417_ignore_persisted_cnf LABELS REPL_BACKEND)
############################################
# BEGIN: binlogrouter and avrorouter tests #
############################################

View File

@ -0,0 +1,3 @@
[maxscale]
threads=###threads###
load_persisted_configs=false

View File

@ -0,0 +1,24 @@
/**
* MXS-2417: Ignore persisted configs with load_persisted_configs=false
* https://jira.mariadb.org/browse/MXS-2417
*/
#include "testconnections.h"
int main(int argc, char* argv[])
{
TestConnections test(argc, argv);
test.tprintf("Creating a server and verifying it exists");
test.check_maxctrl("create server server1234 127.0.0.1 3306");
test.check_maxctrl("show server server1234");
test.tprintf("Restarting MaxScale");
test.maxscales->restart_maxscale();
test.tprintf("Creating the server again and verifying it is successful");
test.check_maxctrl("create server server1234 127.0.0.1 3306");
test.check_maxctrl("show server server1234");
return test.global_result;
}