[asterisk-commits] wdoekes: testsuite/asterisk/trunk r3670 - /asterisk/trunk/lib/python/asterisk/
SVN commits to the Asterisk project
asterisk-commits at lists.digium.com
Wed Mar 20 15:02:57 CDT 2013
Author: wdoekes
Date: Wed Mar 20 15:02:53 2013
New Revision: 3670
URL: http://svnview.digium.com/svn/testsuite?view=rev&rev=3670
Log:
Don't pass strings to Deferred.errback(). Pass exceptions.
Review: https://reviewboard.asterisk.org/r/2397/
Modified:
asterisk/trunk/lib/python/asterisk/TestCase.py
asterisk/trunk/lib/python/asterisk/asterisk.py
Modified: asterisk/trunk/lib/python/asterisk/TestCase.py
URL: http://svnview.digium.com/svn/testsuite/asterisk/trunk/lib/python/asterisk/TestCase.py?view=diff&rev=3670&r1=3669&r2=3670
==============================================================================
--- asterisk/trunk/lib/python/asterisk/TestCase.py (original)
+++ asterisk/trunk/lib/python/asterisk/TestCase.py Wed Mar 20 15:02:53 2013
@@ -248,7 +248,7 @@
""" Make sure the instances started properly """
for (success, value) in result:
if not success:
- logger.error(value)
+ logger.error(value.getErrorMessage())
self.stop_reactor()
return result
@@ -304,7 +304,7 @@
""" Make sure the instances stopped properly """
for (success, value) in result:
if not success:
- logger.warning(value)
+ logger.warning(value.getErrorMessage())
# This should already be called when the reactor is being terminated.
# If we couldn't stop the instance of Asterisk, there isn't much else to do
# here other then complain
Modified: asterisk/trunk/lib/python/asterisk/asterisk.py
URL: http://svnview.digium.com/svn/testsuite/asterisk/trunk/lib/python/asterisk/asterisk.py?view=diff&rev=3670&r1=3669&r2=3670
==============================================================================
--- asterisk/trunk/lib/python/asterisk/asterisk.py (original)
+++ asterisk/trunk/lib/python/asterisk/asterisk.py Wed Mar 20 15:02:53 2013
@@ -255,7 +255,7 @@
""" Errback for CLI command waitfullybooted """
if time.time() - self.__start_asterisk_time > 5:
logger.error("Asterisk core waitfullybooted for %s failed" % self.host)
- self.__start_deferred.errback("Command core waitfullybooted failed")
+ self.__start_deferred.errback(Exception("Command core waitfullybooted failed"))
else:
logger.debug("Asterisk core waitfullybooted failed, attempting again...")
reactor.callLater(0, __execute_wait_fully_booted)
More information about the asterisk-commits
mailing list