Commit Graph

504 Commits

Author SHA1 Message Date
5b0b1666cc Fix bug649
The `Test` is a pointer.
2017-09-28 10:39:37 +03:00
099c2f87bc MXS-1457: Add test case
Added a test that reproduces the problem.
2017-09-27 19:28:05 +03:00
3922f7a901 Enable tee filter tests for 2.2
Enabled the tests that were accidentally disabled and cleaned up some of
the redundant code in bug649.
2017-09-27 19:26:05 +03:00
2633ad2fe4 Merge branch '2.1' into 2.2 2017-09-26 14:29:14 +03:00
753c61997d MXS-1451: Expand test case
The test now checks that both users with passwords and users without
passwords work through MaxScale when skip_authentication is enabled. In
addition to this, the test also makes sure that the wrong password and a
missing password are properly detected.
2017-09-26 07:48:45 +03:00
2079bba49c MXS-1451: Calculate password even with skip_authentication=true
The result of the authentication should be ignored but the scramble that
is calculated as a side-effect still needs to be stored. This can be done
by altering the SQL used to get the matching row to only match on the
username, not the network address.

Also expanded the test case to cover the use of bad credentials.
2017-09-25 19:00:44 +03:00
6601f15ff8 MXS-1451: Add test case
Added test case for MXS-1451 that reproduces the problem.
2017-09-25 13:27:55 +03:00
551bfb6f26 Merge branch '2.1' into 2.2 2017-09-25 12:35:11 +03:00
18b0d3575e Speed up binlog tests
The binlogrouter tests can safely use the sync_slaves functionality of the
test framework as long as a sensible timeout is used.

Cleaned up the tests by removing redundant code and allocating classes
from the stack thus removing the need to handle memory allocation.
2017-09-25 10:46:55 +03:00
9f31b746a0 Create rules directory in mxs1110_16mb
The test uses the dbfwfilter but it does not create the directory where
the rules are stored.
2017-09-25 10:46:55 +03:00
14920fef6c Enable info log for mxs1110_16mb
The info log should help resolve why MaxScale crashes with a debug
assertion.
2017-09-25 10:46:55 +03:00
b1859cc7a5 Speed up lots_of_rows
The test inserted 200k rows with autocommit enabled which made it very
slow. Wrapping the inserts inside a transaction gives the test a
significant speed boost.
2017-09-25 10:46:55 +03:00
54f4c6ff73 Clean up binlog_semisync
Removed unnecessary newlines and for loops that were executed only once.
2017-09-25 10:46:55 +03:00
ba47d80efa Only test edge cases in different_size tests
The tests should only test the cases when the payload size changes the
number of packets the query generates. This involves generating only one
packet, one full packet and one partial packet and one full packet and one
empty packet. These cases should cover all reasonable edge cases and
further testing doesn't seem to provide any significant benefit.
2017-09-25 10:46:55 +03:00
eb0f8ef25d Drop unused databases
The test code should drop any databases that it creates. Also fixed the
typo in the database name.
2017-09-21 09:42:38 +03:00
595827f9f0 Clean up pers_01 test
The test used an unnecessary timeout in places where one is not
expected. It also restarted MaxScale with no apparent reason.
2017-09-21 09:36:50 +03:00
cda1fdc26a Refactor fwf_syntax
Use stack allocated classes, check return value of the start command and
combine the rule creation function.
2017-09-21 09:36:50 +03:00
049eb68254 Combine redundant dbfwfilter tests
The fwf test now only tests the functionality of the rules themselves, not
the parsing. The fwf_syntax test handles the testing of the parser. The
fwf2 test was removed as it was almost identical with the original fwf
test.
2017-09-21 09:36:50 +03:00
773bae1615 Speed up testing
Removed unnecessary sleeps from tests that appear to serve no
purpose. Moveed the kerberos code from the general startup routines to the
kerberos test.
2017-09-21 09:36:50 +03:00
20bfe16d11 Remove unnecessary sleeps
Every time MaxScale was restarted, the test waited for a total of 25
seconds. As MaxScale should start before the command returns, the sleep is
not necessary.

Added StartLimitBurst=0 to the systemd service file to allow rapid
restarts of MaxScale.
2017-09-21 09:36:50 +03:00
481ad080ef MXS-1295: Add test case
The test case checks that the strict_sp_calls parameter works as expected.
2017-09-20 11:18:16 +03:00
68bcd00a22 Merge branch '2.1' into develop 2017-09-20 10:47:53 +03:00
1067e76121 Fix CMake variables of cdc_connector
The library is not a static library but a shared object.
2017-09-19 11:18:21 +03:00
a26f6f6087 Make run_session_hang.sh shorter
The test was unnecessarily long.
2017-09-19 10:11:42 +03:00
6b22865f7d MXS-1413: Make the library dynamic
The static library cannot be linked to the Jansson static library by
CMake. This appears to be a limitation in CMake and a manual combination
of the two files would be required.

For the time being, the connector is only built as a shared library.
2017-09-19 06:55:49 +03:00
062a358077 MXS-1413: Make the CDC connector a standalone library
The library is still located in the test directory but the way it is now
built allows it to be used like a standalone library
2017-09-19 06:55:49 +03:00
3541d6e0a4 MXS-1413: Add row processing to cdc_connector
The connector now processes rows into objects which expose the values and
types of each returned row.
2017-09-19 06:55:49 +03:00
36ec6e443e MXS-1413: Use JSON_ALLOW_NUL when loading JSON
The cdc_result.cpp uses json_loads to extract the JSON and JSON_ALLOW_NUL
needs to be added to allow null unicode characters to be extracted.
2017-09-19 06:55:49 +03:00
52da6c0214 MXS-1413: Move cdc_connector into a subdirectory
Moved the cdc_connector into a subdirectory to distinct it from the other
test sources.
2017-09-19 06:55:49 +03:00
a4bad5ffd2 Use shorter timeouts in mxs1323_retry_read
The configuration for mxs1323_retry_read now uses shorter timeouts for
monitors. This should help the monitors detect the server failures before
the result of the SELECT returns. also increased the time the query sleeps
before returning.
2017-09-18 13:46:20 +03:00
6794b35eb0 Remove Python SQL tests
The tests that involved SQL weren't run and did not really test what was
intended to be tested; the use of a Java Connector with MaxScale.
2017-09-18 11:40:43 +03:00
3f0a738e08 Increase timeouts for tests
bug507 and bug519 had relatively low timeouts which seem to be triggered
quite often.
2017-09-17 10:47:06 +03:00
9267f8ad70 MXS-1418: Keep connections open if server is removed
The removal of a server from a service is intended to affect only new
sessions.

Added a test that checks that the connections are kept open even if the
server is removed from the service.
2017-09-16 07:28:17 +03:00
16d3eab59f Merge branch '2.1' into develop 2017-09-12 22:42:11 +03:00
3841205704 Update mxs729_maxadmin
The test expected the old result for the test.
2017-09-12 11:17:19 +03:00
7a8a12dd28 Update CDash drop site address
The drop site was not set to the correct one.
2017-09-12 09:29:26 +03:00
f4cd2c62b6 Backport mxs1110_16mb fixes to 2.1
Backported changes to mxs1110_16mb from develop into 2.1.
2017-09-08 09:54:17 +03:00
0daa167873 Fix bug519
The test attempted to copy the generated CSV file from the MaxScale server
when in fact it was on the master server. Removed HEAVY label from the
test as it takes about 10 seconds to run.

Cherry-picked from commit f80cde2af149fda9c47d8f9131f82527b76af487.
2017-09-08 09:54:17 +03:00
1e2e43a96e MXS-1389: Add test for uses_function
The test uses a uses_function type rule to restrict access to the name and
address columns.
2017-09-08 09:31:38 +03:00
a4975edbba MXS-1389: Fix rule reloading and query parsing requirements
Reloading of rules now properly uses the current rule file if no argument
was provided. The rule version counter also used atomic operations for the
sake of correctness.

The rule parsing is now only required for DML type statements that should
be fully parsed.
2017-09-08 09:31:38 +03:00
f0a9866a87 MXS-1389: Fix fwf test SQL
The SQL executed by the test that was expected to pass wasn't correct
SQL. It appears that a CAST from an INTEGER to a TEXT value is not
possible.
2017-09-08 09:31:38 +03:00
40582c38fb MXS-1389: Fix fwf test rules
The new tests now use the correct syntax for the rule files.
2017-09-08 09:31:38 +03:00
a041bfcb5f Make the fwf test less verbose
The test was very verbose which made spotting the failure cases harder.
2017-09-08 09:31:38 +03:00
11bf5d2412 MXS-1389: Add tests for function use with columns
The test checks that only the functions that aren't allowed are blocked.
2017-09-08 09:31:38 +03:00
9e43ef2af1 Add missing fwf test case
A test case in the fwf test wasn't being run.
2017-09-06 12:07:16 +03:00
5455ffbb7f Update mxs729_maxadmin
The test now expects the correct output.
2017-08-30 13:07:46 +03:00
13f7015e7b Fix EOF packet calculation for large rows
The EOF packet calculation function in modutil.cc didn't handle the case
where the payload exceeded maximum packet size and could mistake binary
data for a ERR packet.

The state of a multi-packet payload is now exposed by the
modutil_count_signal_packets function. This allows proper handling of
large multi-packet payloads.

Added minor improvements to mxs1110_16mb to handle testing of this change.
2017-08-25 17:00:42 +03:00
42efe0549a Add error messages and increse to max_allowed_packet in mxs1110_16mb
The test now logs why it fails to perform some action in addition to
setting max_allowed_packet to both master-slave and Galera clusters.
2017-08-25 13:54:10 +03:00
cbe878409a Fix kerberos test (#139)
* add 'maxscale' and 'node_xxx' names to /etc/hosts and add 'yum clean all'

* add forgotten 'node_xxx' names to /etc/hosts
2017-08-24 12:40:31 +03:00
c794af1f47 Mxs 1355 (#138)
* add binlog test with gtid

* removing ;

* restore test to initial state with check_sha1()

* remove reset master

* make no_vm_revert true by dafault
2017-08-24 12:21:29 +03:00