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.
This commit is contained in:
Markus Mäkelä
2018-11-19 07:58:20 +02:00
parent 778623bdfd
commit 92b4ed2867

View File

@ -2042,14 +2042,14 @@ int TestConnections::revert_snapshot(char* snapshot_name)
bool TestConnections::test_bad_config(int m, const char* config)
{
process_template(m, config, "./");
process_template(m, config, "/tmp/");
// Set the timeout to prevent hangs with configurations that work
set_timeout(20);
return maxscales->ssh_node_f(m,
true,
"cp maxscale.cnf /etc/maxscale.cnf; service maxscale stop; "
"cp /tmp/maxscale.cnf /etc/maxscale.cnf; pkill -9 maxscale; "
"maxscale -U maxscale -lstdout &> /dev/null && sleep 1 && pkill -9 maxscale")
== 0;
}