Add testConnection() method.
Add method for testing connection.