MXS-2266: Add test case
Extended the existing tests to cover MXS-2266.
This commit is contained in:
@ -455,7 +455,7 @@ add_test_executable(mxs359_read_only.cpp mxs359_read_only mxs359_read_only LABEL
|
|||||||
# Test master_failure_mode=error_on_write and master replacement
|
# Test master_failure_mode=error_on_write and master replacement
|
||||||
add_test_executable(mxs359_error_on_write.cpp mxs359_error_on_write mxs359_error_on_write LABELS readwritesplit REPL_BACKEND)
|
add_test_executable(mxs359_error_on_write.cpp mxs359_error_on_write mxs359_error_on_write LABELS readwritesplit REPL_BACKEND)
|
||||||
|
|
||||||
# Binary protocol prepared statement tests
|
# Binary protocol prepared statement tests (also tests MXS-2266)
|
||||||
add_test_executable(binary_ps.cpp binary_ps replication LABELS readwritesplit LIGHT REPL_BACKEND)
|
add_test_executable(binary_ps.cpp binary_ps replication LABELS readwritesplit LIGHT REPL_BACKEND)
|
||||||
add_test_executable(binary_ps_cursor.cpp binary_ps_cursor replication LABELS readwritesplit LIGHT REPL_BACKEND)
|
add_test_executable(binary_ps_cursor.cpp binary_ps_cursor replication LABELS readwritesplit LIGHT REPL_BACKEND)
|
||||||
|
|
||||||
|
@ -46,6 +46,7 @@ int main(int argc, char** argv)
|
|||||||
test.add_result(strcmp(buffer, server_id[0]), "Expected server_id '%s', got '%s'", server_id[0], buffer);
|
test.add_result(strcmp(buffer, server_id[0]), "Expected server_id '%s', got '%s'", server_id[0], buffer);
|
||||||
|
|
||||||
mysql_stmt_close(stmt);
|
mysql_stmt_close(stmt);
|
||||||
|
|
||||||
stmt = mysql_stmt_init(test.maxscales->conn_rwsplit[0]);
|
stmt = mysql_stmt_init(test.maxscales->conn_rwsplit[0]);
|
||||||
|
|
||||||
// Execute read, should return a slave server ID
|
// Execute read, should return a slave server ID
|
||||||
@ -66,5 +67,8 @@ int main(int argc, char** argv)
|
|||||||
|
|
||||||
test.maxscales->close_maxscale_connections(0);
|
test.maxscales->close_maxscale_connections(0);
|
||||||
|
|
||||||
|
// MXS-2266: COM_STMT_CLOSE causes a warning to be logged
|
||||||
|
test.log_excludes(0, "Closing unknown prepared statement");
|
||||||
|
|
||||||
return test.global_result;
|
return test.global_result;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user