[asterisk-commits] mjordan: testsuite/asterisk/trunk r3617 - in /asterisk/trunk/tests/apps: conf...

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Tue Jan 22 14:50:42 CST 2013


Author: mjordan
Date: Tue Jan 22 14:50:37 2013
New Revision: 3617

URL: http://svnview.digium.com/svn/testsuite?view=rev&rev=3617
Log:
Update tests that act on PLAYBACK test suite events to not fail

A number of tests assumed that a 'message' field would always be present
in a PLAYBACK TestSuite event. That's not exactly true any longer.

Added:
    asterisk/trunk/tests/apps/mixmonitor/testaudio1.raw   (with props)
    asterisk/trunk/tests/apps/mixmonitor/testaudio2.raw   (with props)
    asterisk/trunk/tests/apps/mixmonitor/testaudio3.raw   (with props)
Modified:
    asterisk/trunk/tests/apps/confbridge/confbridge_nominal/run-test
    asterisk/trunk/tests/apps/voicemail/authenticate_extensions/run-test
    asterisk/trunk/tests/apps/voicemail/authenticate_invalid_mailbox/run-test
    asterisk/trunk/tests/apps/voicemail/authenticate_invalid_password/run-test
    asterisk/trunk/tests/apps/voicemail/authenticate_nominal/run-test
    asterisk/trunk/tests/apps/voicemail/check_voicemail_callback/run-test
    asterisk/trunk/tests/apps/voicemail/check_voicemail_delete/run-test
    asterisk/trunk/tests/apps/voicemail/check_voicemail_dialout/run-test
    asterisk/trunk/tests/apps/voicemail/check_voicemail_envelope/run-test
    asterisk/trunk/tests/apps/voicemail/check_voicemail_forward/run-test
    asterisk/trunk/tests/apps/voicemail/check_voicemail_forward_hangup/run-test
    asterisk/trunk/tests/apps/voicemail/check_voicemail_forward_with_prepend/run-test
    asterisk/trunk/tests/apps/voicemail/check_voicemail_new_user/run-test
    asterisk/trunk/tests/apps/voicemail/check_voicemail_new_user_hangup/run-test
    asterisk/trunk/tests/apps/voicemail/check_voicemail_nominal/run-test
    asterisk/trunk/tests/apps/voicemail/check_voicemail_options_change_password/run-test
    asterisk/trunk/tests/apps/voicemail/check_voicemail_options_record_busy/run-test
    asterisk/trunk/tests/apps/voicemail/check_voicemail_options_record_name/run-test
    asterisk/trunk/tests/apps/voicemail/check_voicemail_options_record_temp/run-test
    asterisk/trunk/tests/apps/voicemail/check_voicemail_options_record_unavail/run-test
    asterisk/trunk/tests/apps/voicemail/check_voicemail_reply/run-test
    asterisk/trunk/tests/apps/voicemail/check_voicemail_while_leaving_msg/run-test
    asterisk/trunk/tests/apps/voicemail/leave_voicemail_contexts/run-test
    asterisk/trunk/tests/apps/voicemail/leave_voicemail_forwarding/run-test
    asterisk/trunk/tests/apps/voicemail/leave_voicemail_forwarding_auto_urgent/run-test
    asterisk/trunk/tests/apps/voicemail/leave_voicemail_nominal/run-test
    asterisk/trunk/tests/apps/voicemail/leave_voicemail_priority/run-test
    asterisk/trunk/tests/apps/voicemail/play_message/run-test

Modified: asterisk/trunk/tests/apps/confbridge/confbridge_nominal/run-test
URL: http://svnview.digium.com/svn/testsuite/asterisk/trunk/tests/apps/confbridge/confbridge_nominal/run-test?view=diff&rev=3617&r1=3616&r2=3617
==============================================================================
--- asterisk/trunk/tests/apps/confbridge/confbridge_nominal/run-test (original)
+++ asterisk/trunk/tests/apps/confbridge/confbridge_nominal/run-test Tue Jan 22 14:50:37 2013
@@ -55,7 +55,7 @@
             if "Bridge" in channel:
                 self.__bridge_channel = channel
         if state == 'PLAYBACK' and channel != "":
-            playfile = event['message']
+            playfile = event.get('message')
             if playfile == 'conf-getpin':
                 self.__handle_pin(channel)
             elif playfile == 'vm-rec-name':
@@ -158,10 +158,10 @@
         if 'channel' in event:
             channel = event['channel']
         if state == 'CONF_MUTE':
-            if channel == self.__admin_channel and "unmuted" in event['message']:
+            if channel == self.__admin_channel and "unmuted" in event.get('message'):
                 self.testCase.expectedEvents['adminunmuted'] = True
         elif state == 'PLAYBACK' and channel != "":
-            playfile = event['message']
+            playfile = event.get('message')
             if playfile == 'conf-hasleft':
                 self.__left_notifications += 1
                 if (self.__left_notifications == 2):

Added: asterisk/trunk/tests/apps/mixmonitor/testaudio1.raw
URL: http://svnview.digium.com/svn/testsuite/asterisk/trunk/tests/apps/mixmonitor/testaudio1.raw?view=auto&rev=3617
==============================================================================
Binary file - no diff available.

Propchange: asterisk/trunk/tests/apps/mixmonitor/testaudio1.raw
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Added: asterisk/trunk/tests/apps/mixmonitor/testaudio2.raw
URL: http://svnview.digium.com/svn/testsuite/asterisk/trunk/tests/apps/mixmonitor/testaudio2.raw?view=auto&rev=3617
==============================================================================
Binary file - no diff available.

Propchange: asterisk/trunk/tests/apps/mixmonitor/testaudio2.raw
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Added: asterisk/trunk/tests/apps/mixmonitor/testaudio3.raw
URL: http://svnview.digium.com/svn/testsuite/asterisk/trunk/tests/apps/mixmonitor/testaudio3.raw?view=auto&rev=3617
==============================================================================
Binary file - no diff available.

Propchange: asterisk/trunk/tests/apps/mixmonitor/testaudio3.raw
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Modified: asterisk/trunk/tests/apps/voicemail/authenticate_extensions/run-test
URL: http://svnview.digium.com/svn/testsuite/asterisk/trunk/tests/apps/voicemail/authenticate_extensions/run-test?view=diff&rev=3617&r1=3616&r2=3617
==============================================================================
--- asterisk/trunk/tests/apps/voicemail/authenticate_extensions/run-test (original)
+++ asterisk/trunk/tests/apps/voicemail/authenticate_extensions/run-test Tue Jan 22 14:50:37 2013
@@ -32,7 +32,7 @@
     def handleStateChange(self, ami, event):
         state = event['state']
         if state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
             if message == 'vm-login':
                 self.voiceMailTest.sendDTMF("1234")
             elif message == 'vm-password':
@@ -66,7 +66,7 @@
     def handleStateChange(self, ami, event):
         state = event['state']
         if state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
             if message == 'vm-login':
                 """ Don't login - just ask to be transferred """
                 self.voiceMailTest.sendDTMF("*")

Modified: asterisk/trunk/tests/apps/voicemail/authenticate_invalid_mailbox/run-test
URL: http://svnview.digium.com/svn/testsuite/asterisk/trunk/tests/apps/voicemail/authenticate_invalid_mailbox/run-test?view=diff&rev=3617&r1=3616&r2=3617
==============================================================================
--- asterisk/trunk/tests/apps/voicemail/authenticate_invalid_mailbox/run-test (original)
+++ asterisk/trunk/tests/apps/voicemail/authenticate_invalid_mailbox/run-test Tue Jan 22 14:50:37 2013
@@ -33,7 +33,7 @@
     def handleStateChange(self, ami, event):
         state = event['state']
         if state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
             if message == 'vm-login' or message == 'vm-incorrect-mailbox':
                 self.voiceMailTest.sendDTMF("5555")
                 self.voiceMailTest.reset_timeout()

Modified: asterisk/trunk/tests/apps/voicemail/authenticate_invalid_password/run-test
URL: http://svnview.digium.com/svn/testsuite/asterisk/trunk/tests/apps/voicemail/authenticate_invalid_password/run-test?view=diff&rev=3617&r1=3616&r2=3617
==============================================================================
--- asterisk/trunk/tests/apps/voicemail/authenticate_invalid_password/run-test (original)
+++ asterisk/trunk/tests/apps/voicemail/authenticate_invalid_password/run-test Tue Jan 22 14:50:37 2013
@@ -32,7 +32,7 @@
     def handleStateChange(self, ami, event):
         state = event['state']
         if state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
             if message == 'vm-login' or message == 'vm-incorrect-mailbox':
                 self.voiceMailTest.sendDTMF("1234")
             elif message == 'vm-password':
@@ -63,7 +63,7 @@
     def handleStateChange(self, ami, event):
         state = event['state']
         if state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
             if message == 'vm-password':
                 self.voiceMailTest.sendDTMF("5555")
                 self.voiceMailTest.reset_timeout()

Modified: asterisk/trunk/tests/apps/voicemail/authenticate_nominal/run-test
URL: http://svnview.digium.com/svn/testsuite/asterisk/trunk/tests/apps/voicemail/authenticate_nominal/run-test?view=diff&rev=3617&r1=3616&r2=3617
==============================================================================
--- asterisk/trunk/tests/apps/voicemail/authenticate_nominal/run-test (original)
+++ asterisk/trunk/tests/apps/voicemail/authenticate_nominal/run-test Tue Jan 22 14:50:37 2013
@@ -34,7 +34,7 @@
     def handleStateChange(self, ami, event):
         state = event['state']
         if state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
             if message == 'vm-login':
                 self.voiceMailTest.sendDTMF(self.mailbox)
             elif message == 'vm-password':
@@ -70,7 +70,7 @@
     def handleStateChange(self, ami, event):
         state = event['state']
         if state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
             if message == 'vm-password':
                 self.voiceMailTest.sendDTMF(self.password)
                 self.voiceMailTest.reset_timeout()

Modified: asterisk/trunk/tests/apps/voicemail/check_voicemail_callback/run-test
URL: http://svnview.digium.com/svn/testsuite/asterisk/trunk/tests/apps/voicemail/check_voicemail_callback/run-test?view=diff&rev=3617&r1=3616&r2=3617
==============================================================================
--- asterisk/trunk/tests/apps/voicemail/check_voicemail_callback/run-test (original)
+++ asterisk/trunk/tests/apps/voicemail/check_voicemail_callback/run-test Tue Jan 22 14:50:37 2013
@@ -42,7 +42,7 @@
         state = event['state']
 
         if state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
             if message == 'vm-password':
                 self.voiceMailTest.sendDTMF(self.userPassword)
         elif state == 'AUTHENTICATED':
@@ -69,7 +69,7 @@
             logger.error("received two authenticated events?")
             self.changeState(FailureTestState(self.controller))
         elif state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
 
             """ We should not be a new user """
             if message == 'new user':
@@ -99,7 +99,7 @@
         if state == 'BROWSE':
             self.changeState(BrowseMessageTestState(self.controller, self.voiceMailTest))
         elif state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
 
             if message == 'instructions':
                 """ Play the message """
@@ -146,7 +146,7 @@
         state = event['state']
 
         if state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
 
             if message == 'vm-tocallback':
                 """ Dial 2 to call back """
@@ -178,7 +178,7 @@
         state = event['state']
 
         if state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
 
             if message == 'instructions':
                 """ Instruct the server to goto the advanced options """

Modified: asterisk/trunk/tests/apps/voicemail/check_voicemail_delete/run-test
URL: http://svnview.digium.com/svn/testsuite/asterisk/trunk/tests/apps/voicemail/check_voicemail_delete/run-test?view=diff&rev=3617&r1=3616&r2=3617
==============================================================================
--- asterisk/trunk/tests/apps/voicemail/check_voicemail_delete/run-test (original)
+++ asterisk/trunk/tests/apps/voicemail/check_voicemail_delete/run-test Tue Jan 22 14:50:37 2013
@@ -42,7 +42,7 @@
         state = event['state']
 
         if state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
 
             if message == 'vm-password':
                 self.voiceMailTest.sendDTMF(self.userPassword)
@@ -72,7 +72,7 @@
         elif state == 'INTRO':
             self.changeState(IntroTestState(self.controller, self.voiceMailTest))
         elif state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
             if message == 'new user':
                 logger.error("New user played; user credentials must have failed")
                 self.changeState(FailureTestState(self.controller))
@@ -98,7 +98,7 @@
         if state == 'BROWSE':
             self.changeState(BrowseMessageTestState(self.controller, self.voiceMailTest))
         elif state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
 
             if message == 'instructions':
                 """ Play the first message """
@@ -124,7 +124,7 @@
         if state == 'PLAYVOICE':
             self.changeState(PlayVoiceMailTestState(self.controller, self.voiceMailTest))
         elif state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
 
             if message == 'instructions':
                 """ Exit voicemail """
@@ -155,7 +155,7 @@
         state = event['state']
 
         if state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
 
             if message == 'instructions':
                 """ Instruct the server to delete the voicemail """

Modified: asterisk/trunk/tests/apps/voicemail/check_voicemail_dialout/run-test
URL: http://svnview.digium.com/svn/testsuite/asterisk/trunk/tests/apps/voicemail/check_voicemail_dialout/run-test?view=diff&rev=3617&r1=3616&r2=3617
==============================================================================
--- asterisk/trunk/tests/apps/voicemail/check_voicemail_dialout/run-test (original)
+++ asterisk/trunk/tests/apps/voicemail/check_voicemail_dialout/run-test Tue Jan 22 14:50:37 2013
@@ -42,7 +42,7 @@
         state = event['state']
 
         if state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
 
             if message == 'vm-password':
                 self.voiceMailTest.sendDTMF(self.userPassword)
@@ -71,7 +71,7 @@
         elif state == 'INTRO':
             self.changeState(IntroTestState(self.controller, self.voiceMailTest))
         elif state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
             if message == 'new user':
                 logger.error("New user played; user credentials must have failed")
                 self.changeState(FailureTestState(self.controller))
@@ -97,7 +97,7 @@
         if state == 'BROWSE':
             self.changeState(BrowseMessageTestState(self.controller, self.voiceMailTest))
         elif state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
 
             if message == 'instructions':
                 """ Play the message """
@@ -144,7 +144,7 @@
         state = event['state']
 
         if state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
 
             if message == 'vm-tomakecall':
                 """ Dial 4 to dialout """
@@ -171,7 +171,7 @@
         state = event['state']
 
         if state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
 
             if message == 'instructions':
                 """ Instruct the server to goto the advanced options """

Modified: asterisk/trunk/tests/apps/voicemail/check_voicemail_envelope/run-test
URL: http://svnview.digium.com/svn/testsuite/asterisk/trunk/tests/apps/voicemail/check_voicemail_envelope/run-test?view=diff&rev=3617&r1=3616&r2=3617
==============================================================================
--- asterisk/trunk/tests/apps/voicemail/check_voicemail_envelope/run-test (original)
+++ asterisk/trunk/tests/apps/voicemail/check_voicemail_envelope/run-test Tue Jan 22 14:50:37 2013
@@ -42,7 +42,7 @@
         state = event['state']
 
         if state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
 
             if message == 'vm-password':
                 self.voiceMailTest.sendDTMF(self.userPassword)
@@ -72,7 +72,7 @@
         elif state == 'INTRO':
             self.changeState(IntroTestState(self.controller, self.voiceMailTest))
         elif state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
             if message == 'new user':
                 logger.error("New user played; user credentials must have failed")
                 self.changeState(FailureTestState(self.controller))
@@ -98,7 +98,7 @@
         if state == 'BROWSE':
             self.changeState(BrowseMessageTestState(self.controller, self.voiceMailTest))
         elif state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
 
             if message == 'instructions':
                 """ Play the first message """
@@ -124,7 +124,7 @@
         if state == 'PLAYVOICE':
             self.changeState(PlayVoiceMailTestState(self.controller, self.voiceMailTest))
         elif state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
 
             if message == 'instructions':
                 """ Exit voicemail """
@@ -161,7 +161,7 @@
         if state == 'SAVEMSG':
             self.changeState(SaveMessageTestState(self.controller, self.voiceMailTest))
         elif state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
 
             if message == 'instructions':
                 """ Instruct the server to save the voicemail """
@@ -185,7 +185,7 @@
         state = event['state']
 
         if state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
 
             if message == 'instructions':
                 """ Tell it to save the message """
@@ -216,7 +216,7 @@
         state = event['state']
 
         if state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
 
             if message == 'instructions':
                 """ Tell it to play the next the message """

Modified: asterisk/trunk/tests/apps/voicemail/check_voicemail_forward/run-test
URL: http://svnview.digium.com/svn/testsuite/asterisk/trunk/tests/apps/voicemail/check_voicemail_forward/run-test?view=diff&rev=3617&r1=3616&r2=3617
==============================================================================
--- asterisk/trunk/tests/apps/voicemail/check_voicemail_forward/run-test (original)
+++ asterisk/trunk/tests/apps/voicemail/check_voicemail_forward/run-test Tue Jan 22 14:50:37 2013
@@ -44,7 +44,7 @@
         state = event['state']
 
         if state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
 
             if message == 'vm-login':
                 self.voiceMailTest.sendDTMF(self.mailbox)
@@ -76,7 +76,7 @@
         elif state == 'INTRO':
             self.changeState(IntroTestState(self.controller, self.voiceMailTest))
         elif state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
 
             if message == 'new user':
                 logger.error("New user played; user credentials must have failed")
@@ -103,7 +103,7 @@
         if state == 'BROWSE':
             self.changeState(BrowseMessageTestState(self.controller, self.voiceMailTest))
         elif state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
 
             if message == 'instructions':
                 """ Play the first message """
@@ -129,7 +129,7 @@
         if state == 'PLAYVOICE':
             self.changeState(PlayVoiceMailTestState(self.controller, self.voiceMailTest))
         elif state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
 
             if message == 'instructions':
                 """ Exit voicemail """
@@ -160,7 +160,7 @@
         if state == 'FORWARD':
             self.changeState(ForwardTestState(self.controller, self.voiceMailTest))
         elif state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
 
             if message == 'instructions':
                 """ Instruct the server to forward the voicemail """
@@ -184,7 +184,7 @@
         state = event['state']
 
         if state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
 
             if message == 'vm-forward':
                 """ Tell it to not use the directory """

Modified: asterisk/trunk/tests/apps/voicemail/check_voicemail_forward_hangup/run-test
URL: http://svnview.digium.com/svn/testsuite/asterisk/trunk/tests/apps/voicemail/check_voicemail_forward_hangup/run-test?view=diff&rev=3617&r1=3616&r2=3617
==============================================================================
--- asterisk/trunk/tests/apps/voicemail/check_voicemail_forward_hangup/run-test (original)
+++ asterisk/trunk/tests/apps/voicemail/check_voicemail_forward_hangup/run-test Tue Jan 22 14:50:37 2013
@@ -44,7 +44,7 @@
         state = event['state']
 
         if state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
 
             if message == 'vm-login':
                 self.voiceMailTest.sendDTMF(self.mailbox)
@@ -76,7 +76,7 @@
         elif state == 'INTRO':
             self.changeState(IntroTestState(self.controller, self.voiceMailTest))
         elif state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
             if message == 'new user':
                 logger.error("New user played; user credentials must have failed")
                 self.changeState(FailureTestState(self.controller))
@@ -102,7 +102,7 @@
         if state == 'BROWSE':
             self.changeState(BrowseMessageTestState(self.controller, self.voiceMailTest))
         elif state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
 
             if message == 'instructions':
                 """ Play the first message """
@@ -128,7 +128,7 @@
         if state == 'PLAYVOICE':
             self.changeState(PlayVoiceMailTestState(self.controller, self.voiceMailTest))
         elif state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
 
             if message == 'instructions':
                 """ Exit voicemail """
@@ -159,7 +159,7 @@
         if state == 'FORWARD':
             self.changeState(ForwardTestState(self.controller, self.voiceMailTest))
         elif state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
 
             if message == 'instructions':
                 """ Instruct the server to forward the voicemail """
@@ -183,7 +183,7 @@
         state = event['state']
 
         if state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
 
             if message == 'vm-forward':
                 """ Tell it to not use the directory """

Modified: asterisk/trunk/tests/apps/voicemail/check_voicemail_forward_with_prepend/run-test
URL: http://svnview.digium.com/svn/testsuite/asterisk/trunk/tests/apps/voicemail/check_voicemail_forward_with_prepend/run-test?view=diff&rev=3617&r1=3616&r2=3617
==============================================================================
--- asterisk/trunk/tests/apps/voicemail/check_voicemail_forward_with_prepend/run-test (original)
+++ asterisk/trunk/tests/apps/voicemail/check_voicemail_forward_with_prepend/run-test Tue Jan 22 14:50:37 2013
@@ -44,7 +44,7 @@
         state = event['state']
 
         if state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
             if message == 'vm-login':
                 self.voiceMailTest.sendDTMF(self.mailbox)
             elif message == 'vm-password':
@@ -75,7 +75,7 @@
         elif state == 'INTRO':
             self.changeState(IntroTestState(self.controller, self.voiceMailTest))
         elif state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
             if message == 'new user':
                 logger.error("New user played; user credentials must have failed")
                 self.changeState(FailureTestState(self.controller))
@@ -101,7 +101,7 @@
         if state == 'BROWSE':
             self.changeState(BrowseMessageTestState(self.controller, self.voiceMailTest))
         elif state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
 
             if message == 'instructions':
                 """ Play the first message """
@@ -127,7 +127,7 @@
         if state == 'PLAYVOICE':
             self.changeState(PlayVoiceMailTestState(self.controller, self.voiceMailTest))
         elif state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
 
             if message == 'instructions':
                 """ Exit voicemail """
@@ -158,7 +158,7 @@
         if state == 'FORWARD':
             self.changeState(ForwardTestState(self.controller, self.voiceMailTest))
         elif state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
 
             if message == 'instructions':
                 """ Instruct the server to forward the voicemail """
@@ -182,7 +182,7 @@
         state = event['state']
 
         if state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
 
             if message == 'vm-forward':
                 """ Tell it to not use the directory """

Modified: asterisk/trunk/tests/apps/voicemail/check_voicemail_new_user/run-test
URL: http://svnview.digium.com/svn/testsuite/asterisk/trunk/tests/apps/voicemail/check_voicemail_new_user/run-test?view=diff&rev=3617&r1=3616&r2=3617
==============================================================================
--- asterisk/trunk/tests/apps/voicemail/check_voicemail_new_user/run-test (original)
+++ asterisk/trunk/tests/apps/voicemail/check_voicemail_new_user/run-test Tue Jan 22 14:50:37 2013
@@ -44,7 +44,7 @@
         state = event['state']
 
         if state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
             if message == 'vm-login':
                 self.voiceMailTest.sendDTMF(self.userMailbox)
             elif message == 'vm-password':
@@ -78,7 +78,7 @@
         elif state == 'INTRO':
             self.changeState(IntroTestState(self.controller, self.voiceMailTest))
         elif state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
             """
             The only prompt that we care about in this state is if we get a notification that we are a new user.
             Record the fact that we heard the prompt
@@ -126,7 +126,7 @@
                 logger.error("unknown password source [" + source + "]")
                 self.changeState(FailureTestState(self.controller))
         elif state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
 
             if message == 'vm-newpassword':
                 """ Change our password to something other than the default of 1234 """
@@ -178,7 +178,7 @@
         state = event['state']
 
         if state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
             if message == 'instructions':
                 """ Tell it to exit out of voicemail """
                 self.voiceMailTest.sendDTMF("#")

Modified: asterisk/trunk/tests/apps/voicemail/check_voicemail_new_user_hangup/run-test
URL: http://svnview.digium.com/svn/testsuite/asterisk/trunk/tests/apps/voicemail/check_voicemail_new_user_hangup/run-test?view=diff&rev=3617&r1=3616&r2=3617
==============================================================================
--- asterisk/trunk/tests/apps/voicemail/check_voicemail_new_user_hangup/run-test (original)
+++ asterisk/trunk/tests/apps/voicemail/check_voicemail_new_user_hangup/run-test Tue Jan 22 14:50:37 2013
@@ -44,7 +44,7 @@
         state = event['state']
 
         if state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
             if message == 'vm-login':
                 self.voiceMailTest.sendDTMF(self.userMailbox)
             elif message == 'vm-password':
@@ -77,7 +77,7 @@
         elif state == 'INTRO':
             self.changeState(IntroTestState(self.controller, self.voiceMailTest))
         elif state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
             if message == 'vm-newuser':
                 logger.debug("New user played")
                 self.voiceMailTest.setTestCondition("newUserPromptPlayed", True)
@@ -121,7 +121,7 @@
                 logger.error("Unknown password source [" + source + "]")
                 self.changeState(FailureTestState(self.controller))
         elif state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
 
             if message == 'vm-newpassword':
                 """ Change our password to something other than the default of 1234 """
@@ -173,7 +173,7 @@
         state = event['state']
 
         if state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
 
             if message == 'instructions':
                 """ Tell it to exit out of voicemail """

Modified: asterisk/trunk/tests/apps/voicemail/check_voicemail_nominal/run-test
URL: http://svnview.digium.com/svn/testsuite/asterisk/trunk/tests/apps/voicemail/check_voicemail_nominal/run-test?view=diff&rev=3617&r1=3616&r2=3617
==============================================================================
--- asterisk/trunk/tests/apps/voicemail/check_voicemail_nominal/run-test (original)
+++ asterisk/trunk/tests/apps/voicemail/check_voicemail_nominal/run-test Tue Jan 22 14:50:37 2013
@@ -46,7 +46,7 @@
             While we're in the START state, we have to authenticate the user.  If we see the login or password
             prompts, send in our login / password
             """
-            message = event['message']
+            message = event.get('message')
             if message == 'vm-password':
                 self.voiceMailTest.sendDTMF(self.userPassword)
         elif state == 'AUTHENTICATED':
@@ -77,7 +77,7 @@
         elif state == 'INTRO':
             self.changeState(IntroTestState(self.controller, self.voiceMailTest))
         elif state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
 
             """
             The only prompt that we care about in this state is if we get a notification that we are a new user.
@@ -110,7 +110,7 @@
         if state == 'BROWSE':
             self.changeState(BrowseMessageTestState(self.controller, self.voiceMailTest))
         elif state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
 
             if message == 'instructions':
                 """
@@ -141,7 +141,7 @@
         if state == 'PLAYVOICE':
             self.changeState(PlayVoiceMailTestState(self.controller, self.voiceMailTest))
         elif state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
 
             if message == 'instructions':
                 """ Exit voicemail """
@@ -183,7 +183,7 @@
         if state == 'SAVEMSG':
             self.changeState(SaveMessageTestState(self.controller, self.voiceMailTest))
         elif state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
 
             if message == 'instructions':
                 """ Instruct the server to save the voicemail """
@@ -209,7 +209,7 @@
         state = event['state']
 
         if state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
 
             if message == 'instructions':
                 """ Tell it to save the message """
@@ -243,7 +243,7 @@
         state = event['state']
 
         if state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
 
             if message == 'instructions':
                 """ Tell it to play the next the message """

Modified: asterisk/trunk/tests/apps/voicemail/check_voicemail_options_change_password/run-test
URL: http://svnview.digium.com/svn/testsuite/asterisk/trunk/tests/apps/voicemail/check_voicemail_options_change_password/run-test?view=diff&rev=3617&r1=3616&r2=3617
==============================================================================
--- asterisk/trunk/tests/apps/voicemail/check_voicemail_options_change_password/run-test (original)
+++ asterisk/trunk/tests/apps/voicemail/check_voicemail_options_change_password/run-test Tue Jan 22 14:50:37 2013
@@ -45,7 +45,7 @@
         state = event['state']
 
         if state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
             if message == 'vm-login':
                 self.voiceMailTest.sendDTMF(self.userMailbox)
             elif message == 'vm-password':
@@ -98,7 +98,7 @@
         state = event['state']
 
         if state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
 
             if message == 'instructions':
                 if (self.voiceMailTest.getTestCondition("passwordChanged")):
@@ -135,13 +135,13 @@
         elif state == 'INTRO':
             self.changeState(IntroTestState(self.controller, self.voiceMailTest))
         elif state == 'PASSWORDCHANGED':
-            message = event['message']
+            message = event.get('message')
             if "voicemail.conf" in message:
                 self.voiceMailTest.setTestCondition("passwordChanged", True)
             elif "external script" in message:
                 self.voiceMailTest.setTestCondition("externNotifyReceived", True)
         elif state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
 
             if message == 'vm-options':
                 if (self.voiceMailTest.getTestCondition("passwordChanged")):

Modified: asterisk/trunk/tests/apps/voicemail/check_voicemail_options_record_busy/run-test
URL: http://svnview.digium.com/svn/testsuite/asterisk/trunk/tests/apps/voicemail/check_voicemail_options_record_busy/run-test?view=diff&rev=3617&r1=3616&r2=3617
==============================================================================
--- asterisk/trunk/tests/apps/voicemail/check_voicemail_options_record_busy/run-test (original)
+++ asterisk/trunk/tests/apps/voicemail/check_voicemail_options_record_busy/run-test Tue Jan 22 14:50:37 2013
@@ -44,7 +44,7 @@
         state = event['state']
 
         if state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
             if message == 'vm-login':
                 self.voiceMailTest.sendDTMF(self.userMailbox)
             elif message == 'vm-password':
@@ -97,7 +97,7 @@
         state = event['state']
 
         if state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
 
             if message == 'instructions':
                 """ Tell it to go to the voicemail options """
@@ -131,7 +131,7 @@
         elif state == 'INTRO':
             self.changeState(IntroTestState(self.controller, self.voiceMailTest))
         elif state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
 
             if message == 'vm-options':
                 if not self.voiceMailTest.getTestCondition('recordBusy'):

Modified: asterisk/trunk/tests/apps/voicemail/check_voicemail_options_record_name/run-test
URL: http://svnview.digium.com/svn/testsuite/asterisk/trunk/tests/apps/voicemail/check_voicemail_options_record_name/run-test?view=diff&rev=3617&r1=3616&r2=3617
==============================================================================
--- asterisk/trunk/tests/apps/voicemail/check_voicemail_options_record_name/run-test (original)
+++ asterisk/trunk/tests/apps/voicemail/check_voicemail_options_record_name/run-test Tue Jan 22 14:50:37 2013
@@ -44,7 +44,7 @@
         state = event['state']
 
         if state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
             if message == 'vm-login':
                 self.voiceMailTest.sendDTMF(self.userMailbox)
             elif message == 'vm-password':
@@ -97,7 +97,7 @@
         state = event['state']
 
         if state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
 
             if message == 'instructions':
                 """ Tell it to go to the voicemail options """
@@ -131,7 +131,7 @@
         elif state == 'INTRO':
             self.changeState(IntroTestState(self.controller, self.voiceMailTest))
         elif state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
 
             if message == 'vm-options':
                 if not self.voiceMailTest.getTestCondition('recordGreeting'):

Modified: asterisk/trunk/tests/apps/voicemail/check_voicemail_options_record_temp/run-test
URL: http://svnview.digium.com/svn/testsuite/asterisk/trunk/tests/apps/voicemail/check_voicemail_options_record_temp/run-test?view=diff&rev=3617&r1=3616&r2=3617
==============================================================================
--- asterisk/trunk/tests/apps/voicemail/check_voicemail_options_record_temp/run-test (original)
+++ asterisk/trunk/tests/apps/voicemail/check_voicemail_options_record_temp/run-test Tue Jan 22 14:50:37 2013
@@ -45,7 +45,7 @@
 
         if state == 'PLAYBACK':
 
-            message = event['message']
+            message = event.get('message')
             if message == 'vm-login':
                 self.voiceMailTest.sendDTMF(self.userMailbox)
             elif message == 'vm-password':
@@ -97,7 +97,7 @@
         state = event['state']
 
         if state == 'PLAYBACK':
-            message = event['message']
+            message = event.get('message')
 
             if message == 'instructions':
                 """ Tell it to go to the voicemail options """

[... 289 lines stripped ...]



More information about the asterisk-commits mailing list