Commit Graph

154 Commits

Author SHA1 Message Date
02395102ed Add log message injection to tests
By injecting messages into the maxscale.log from the test, the reader of
the log can easily see the "synchronization" with the test case. This does
affect the test timing so it can only be used to see whether non-timing
related functionality is correct.
2019-07-03 09:34:20 +03:00
3e85500491 Merge branch '2.3' into 2.4 2019-07-02 08:38:15 +03:00
8ee54b76d6 Merge branch '2.2' into 2.3 2019-07-02 08:36:37 +03:00
fa13ec8c38 Apply MDBCI install_product chnages also to reinstall_maxscale() 2019-07-01 15:12:04 +03:00
64935573b2 Add virtual functions check_replication() and start_replication() for Clustrix
Implementations of check_replication() and start_replication() for Clustrix allows to use fix_replication()
also for Clustrix nodes without checking it.
Also several attempts to check nodes after restart are added - to wait for nodes if they are not running
right after server daemon restart
2019-05-22 15:39:25 +03:00
5828061321 Merge branch '2.3' into develop 2019-05-17 14:39:30 +03:00
f94355770f Merge branch '2.2' into 2.3 2019-05-17 14:10:28 +03:00
677023a18f Move version pronting from call_mdcbi() directly to TestConnectios()
mdbci call can heppen before maxsales object creation and segfault hapens
To avoid it call of ssh for 'maxscale --version-full' is moved to the end
of Testconnections constructor
2019-05-16 14:36:37 +03:00
a3e9ce651f Add 'maxscale --version-full' command to call_mdbci()
Previously Maxscale version check was in the 'check_backend', but this was
removed from the tests execution process. Now 'maxscale --version-full'
is added to nodes creation function - to call_mdbci()
2019-05-15 13:18:27 +03:00
56c27afd0a MXS-2458: add template for Clustrix monitor tests
First implementation of Clustrix setup creation
TODO: move Clustrix installation to MDBCI
2019-05-07 17:17:57 +03:00
643514bbe4 Merge branch '2.3' into develop 2019-04-30 12:46:07 +03:00
08bd7c99be Add a possibility to run tests under callgrind
Flag 'use_callgrind' make all maxscale-system-test run Maxscale under Valgrind with --tool=callgrind option
2019-04-26 17:30:10 +03:00
4ad60fa2a2 Merge branch '2.3' into develop 2019-04-24 13:29:04 +03:00
ddf9002e86 Add tests with big backend
Basic tests can be executed with 15 machines Master/slave backend. Tests have label BIG_REPL_BACKEND Default template modified to support big backend. Tests temporaraly labeled as UNSTABLE to prevent their execution nightly
For big test maxscale.cnf is automatically generated for any number of nodes
2019-04-18 09:48:39 +03:00
802a19879b Merge branch '2.3' of github.com:mariadb-corporation/MaxScale into 2.3 2019-04-18 09:29:20 +03:00
e119077328 Merge branch '2.3' into develop 2019-04-15 16:17:54 +03:00
9941f7d763 Merge branch '2.2' into 2.3 2019-04-15 16:13:04 +03:00
b9aec60d7a Merge branch '2.2' of github.com:mariadb-corporation/MaxScale into 2.2 2019-04-15 15:00:49 +03:00
2e7ef72e3a make ~/.ssh/id_rsa.pub default key for loading into test VMs 2019-04-15 14:59:39 +03:00
74ea0a844c remove whitespace at end of line 2019-04-15 14:56:07 +03:00
eafb7ac5f1 Add tests with big backend
Basic tests can be executed with 15 machines Master/slave backend. Tests have label BIG_REPL_BACKEND Default template modified to support big backend. Tests temporaraly labeled as UNSTABLE to prevent their execution nightly
2019-04-15 14:35:24 +03:00
87741b7190 Add copying of ssh public keys to test VMs
mdbci public_keys command copies ssh public keys from given file to all created VMs
2019-04-15 13:48:19 +03:00
a920534e94 add / to MDBCI_VM_PATH
If case of MDBCI_VM_PATH variable does not have trailing slash full names of _network_config
and _lables files are defined in the wrong way: MDBCI_VM_PATH is interpreted as a part of file name
instead of direcoty name
2019-04-15 13:45:18 +03:00
7ecc70fd5d Move versions checks after nodes checks
In case when nodes/servers/replication/etc in backend are broken test can not
get proper version information and exits without doing anything.
To avoid it, test first checks backend, call fix_replication() if needed
and only after that tris to check if backend version is ok for this test
2019-04-15 13:01:03 +03:00
c643f9bc8d Merge branch '2.3' into develop 2019-04-12 13:23:49 +03:00
0932d10169 Do node checks in parallel
The checking of MariaDB and Galera nodes is now done asynchronously while
the MaxScale check is done which leads to faster testing. Rough
measurements show that doing all the work in parallel reduces test startup
time by two seconds. Most of the time appears to still be in the MaxScale
startup which takes on average three to four seconds per test.
2019-04-09 09:43:19 +03:00
5e3af05d48 Speed up test startup
The VM connectivity and log truncation is now done in parallel.
2019-04-09 09:43:19 +03:00
55bb3e9250 Make tests less verbose
The numeric values of the labels aren't of value when inspecting test
results. For this reason, it makes sense to put them behind the verbose
flag to make test framework debugging happen purpose.
2019-04-09 09:43:19 +03:00
5cdea12ea6 restore test_name processing 2019-04-05 10:31:51 +03:00
2aa3515fc8 Merge commit '09cb4a885f88d30b5108d215dcdaa5163229a230' into develop 2019-04-04 14:34:17 +03:00
cd732ac14f 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
2019-04-02 13:27:34 +03:00
fb96141dda MXS-2243_labels Maxscale system tests prepare environment by themselves
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
2019-03-28 22:37:24 +02:00
2cbfe4fb8a Stop maxscale if it won't be restarted
This makes sure no MaxScales are running when the test is started.
2019-03-25 19:21:12 +02:00
2ba7e63e7e Merge branch '2.3' into develop 2019-03-21 09:26:06 +02:00
805e7975f5 Fix log truncation
Syslog wasn't truncated which caused massive disk space usage when the
full test set was run. Also removed the creation of empty log files if no
messages were logged during the run.
2019-03-18 13:58:04 +02:00
1c3a5bda83 Merge branch '2.3' into develop 2019-03-11 12:29:56 +02:00
c83868936a fix start_maxscale for valgrind case 2019-03-08 11:47:11 +02:00
9572ff84ea Merge branch '2.3' into develop 2019-03-05 10:37:56 +02:00
77ef3dd613 Merge branch '2.2' into 2.3 2019-03-05 04:54:40 +02:00
a6ab05b673 Fix format-overflow warnings in tests
The tests previously ignored these warnings but the change in compiler
flags caused them to fail.
2019-03-04 08:48:32 +02:00
21fc015635 Fix compiler warnings in system tests 2019-02-27 23:15:36 +02:00
2440b48ccc Mxs 2236 own longtest (#189)
MXS-2236 Add own long test and possibility to run tests under Valgrind

Long test executes INSERT queries, transactions, prepared statements in parallel to create weird load on Maxscale to catch crashes and leaks

Test is not included into ctest scope. Test should be executed manually. For BuildBot (and also for run_test.sh) 'test_set' should be set 'NAME# ./long_test'

Time to run test is defined by 'long_test_time' variable (in seconds)

Possibility to run Maxscale under Valgrind is also added. To run Maxscale under Vaslgrind 'use_valgrind=yes' variable have to be defined
2019-02-22 16:12:57 +02:00
968743f61a Fix compiler errors related to unused results 2019-02-01 12:31:53 +02:00
038f4d63e1 Mxs 2226 long test (#186)
* add possibility to run named test

* remove sysbench_dir

* remove unsupported in 1.0 sysbench options

* exculed ReadConnRouter sysbench test

* fix sysbench table name
2018-12-31 17:27:04 +02:00
da1772f8c9 MXS-2146: Add conditional columnstore usage
Tests can now declare that they require a columnstore setup. If one is not
present, the test is skipped.
2018-11-19 20:19:18 +02:00
92b4ed2867 Use explicit paths for bad config location
The test_bad_config used implicit locations which aren't very clear. Using
an explicit path, /tmp/, solves all of these problems.
2018-11-19 20:03:22 +02:00
355f34669d Sanitize log_matches input
Given that the pattern is given as an argument quoted with single quotes,
embedded single quotes are a problem. Given that most cases that they are
used for is as parts of natural words like can't or won't. By replacing
the single quotes with wildcard characters, we make sure the input is
formatted correctly while still matching with relatively high accuracy.
2018-11-19 20:02:12 +02:00
4b6aab1417 Replace check_log_err with log_includes/log_excludes
The latter are more explicit and easier to understand at the call site.

Also removed the redundant crash checks via the log files.
2018-11-19 20:02:11 +02:00
74ec1e7400 Skip tests that cannot be run
If a test requires Galera but it is not available, it is now skipped. All
tests that explicitly use the `test.galera` member as well as all tests
that use a Galera configuration now require that Galera is present.
2018-11-19 20:02:10 +02:00
396da06eb8 Move sync_with_stdio into TestConnections constructor
This way all tests run with the same configuration.
2018-11-15 14:24:41 +02:00