Fix exceptions not to be strings
Signed-off-by: Lucas Meneghel Rodrigues <lucasmr@br.ibm.com>
git-svn-id: http://test.kernel.org/svn/autotest/trunk@1157 592f7852-d20e-0410-864c-8624ca9c26a4
diff --git a/server/hosts/ssh_host.py b/server/hosts/ssh_host.py
index c7b6446..6566918 100644
--- a/server/hosts/ssh_host.py
+++ b/server/hosts/ssh_host.py
@@ -213,7 +213,7 @@
self.__record("GOOD", None, "reboot.start", "hard reset")
if not self.__console_run(r"'~$hardreset'"):
self.__record("ABORT", None, "reboot.start", "hard reset unavailable")
- raise AutoservUnsupportedError
+ raise AutoservUnsupportedError('Hard reset unavailable')
if wait:
self.wait_for_restart(timeout)
@@ -685,7 +685,7 @@
Check that uptime is available and monotonically increasing.
"""
if not self.ping():
- raise "Client is not pingable"
+ raise AutoservHostError('Client is not pingable')
result = self.run("/bin/cat /proc/uptime", 30)
return result.stdout.strip().split()[0]