|
@@ -105,11 +105,12 @@ class TestCheckHost(TestCase):
|
|
|
|
|
|
checkHost.actionexecute(None)
|
|
|
|
|
|
- self.assertEquals(structured_out_mock.call_args[0][0], {'db_connection_check': {'message': 'Error downloading JDBC ' \
|
|
|
- 'connector from Ambari Server resources. Confirm you ran ambari-server setup to ' \
|
|
|
- 'install JDBC connector. Use "ambari-server setup --help" for more information. Check ' \
|
|
|
- 'network access to Ambari Server.\ntest exception', 'exit_code': 1}})
|
|
|
-
|
|
|
+ self.assertEquals(format_mock.call_args[0][0], 'Error: Ambari Server cannot download the database JDBC driver '
|
|
|
+ 'and is unable to test the database connection. You must run ambari-server setup '
|
|
|
+ '--jdbc-db={db_name} --jdbc-driver=/path/to/your/{db_name}/driver.jar on the Ambari '
|
|
|
+ 'Server host to make the JDBC driver available for download and to enable testing '
|
|
|
+ 'the database connection.\n')
|
|
|
+ self.assertEquals(structured_out_mock.call_args[0][0]['db_connection_check']['exit_code'], 1)
|
|
|
self.assertEquals(format_mock.call_args_list[4][0][0], "/bin/sh -c 'cd /usr/lib/ambari-agent/ && curl -kf " \
|
|
|
"--retry 5 {jdbc_url} -o {jdbc_name}'")
|
|
|
|