[asterisk-commits] kmoore: testsuite/asterisk/trunk r5080 - /asterisk/trunk/lib/python/asterisk/

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Wed May 28 16:10:34 CDT 2014


Author: kmoore
Date: Wed May 28 16:10:32 2014
New Revision: 5080

URL: http://svnview.digium.com/svn/testsuite?view=rev&rev=5080
Log:
Testsuite: Allow better subclassing of HangupMonitor

This allows subclasses of HangupMonitor to override module stop behavior.

Modified:
    asterisk/trunk/lib/python/asterisk/pluggable_modules.py

Modified: asterisk/trunk/lib/python/asterisk/pluggable_modules.py
URL: http://svnview.digium.com/svn/testsuite/asterisk/trunk/lib/python/asterisk/pluggable_modules.py?view=diff&rev=5080&r1=5079&r2=5080
==============================================================================
--- asterisk/trunk/lib/python/asterisk/pluggable_modules.py (original)
+++ asterisk/trunk/lib/python/asterisk/pluggable_modules.py Wed May 28 16:10:32 2014
@@ -264,8 +264,12 @@
             return (ami, event)
         if len(self.channels) == 0:
             LOGGER.info("All channels have hungup; stopping test")
-            self.test_object.stop_reactor()
+            self.stop_test()
         return (ami, event)
+
+    def stop_test(self):
+        """Allow subclasses to take different actions to stop the test."""
+        self.test_object.stop_reactor()
 
 
 class CallFiles(object):




More information about the asterisk-commits mailing list