Improve the forced reconnect code in the init_command test.

Instead of using a timeout to trigger a connection close, explicitly kill the connection.
Instead of testing the return value of ping for reconnect, test that the connection ID changed.
Define SECURE_CONNECTION to 0 if not available
Update MySQL 5.7 and other Travis scripts.