MaxScale/maxscale-system-test/mxs1773_failing_ldli.cpp
Markus Mäkelä c0a3e6ba37
MXS-1773: Add test case
Added a test case that reproduces the problem and verifies that it is
fixed.
2018-04-11 09:45:13 +03:00

23 lines
605 B
C++

/**
* MXS-1773: Failing LOAD DATA LOCAL INFILE confuses readwritesplit
*
* https://jira.mariadb.org/browse/MXS-1773
*/
#include "testconnections.h"
#include <functional>
int main(int argc, char** argv)
{
TestConnections test(argc, argv);
test.maxscales->connect();
auto q = std::bind(execute_query, test.maxscales->conn_rwsplit[0], std::placeholders::_1);
q("LOAD DATA LOCAL INFILE '/tmp/this-file-does-not-exist.txt' INTO TABLE this_table_does_not_exist");
q("SELECT 1");
q("SELECT 2");
q("SELECT 3");
test.maxscales->disconnect();
return test.global_result;
}