[asterisk-commits] mjordan: testsuite/asterisk/trunk r2177 - in /asterisk/trunk/tests/apps/voice...

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Mon Sep 12 10:38:12 CDT 2011


Author: mjordan
Date: Mon Sep 12 10:38:08 2011
New Revision: 2177

URL: http://svnview.digium.com/svn/testsuite?view=rev&rev=2177
Log:
Updated authenticate test to remove some unnecessary Wait statements.

Modified:
    asterisk/trunk/tests/apps/voicemail/authenticate_nominal/configs/ast1/extensions.conf
    asterisk/trunk/tests/apps/voicemail/authenticate_nominal/configs/ast2/extensions.conf
    asterisk/trunk/tests/apps/voicemail/authenticate_nominal/run-test

Modified: asterisk/trunk/tests/apps/voicemail/authenticate_nominal/configs/ast1/extensions.conf
URL: http://svnview.digium.com/svn/testsuite/asterisk/trunk/tests/apps/voicemail/authenticate_nominal/configs/ast1/extensions.conf?view=diff&rev=2177&r1=2176&r2=2177
==============================================================================
--- asterisk/trunk/tests/apps/voicemail/authenticate_nominal/configs/ast1/extensions.conf (original)
+++ asterisk/trunk/tests/apps/voicemail/authenticate_nominal/configs/ast1/extensions.conf Mon Sep 12 10:38:08 2011
@@ -9,7 +9,6 @@
     same => n,Verbose(1, Testing no mailbox)
     same => n,VMAuthenticate()
     same => n,UserEvent(TestResult,result: pass,status: Successfully authenticated user)
-    same => n,Wait(5)
     same => n,Hangup()
 
 exten => 9001,1,NoOp()
@@ -17,7 +16,6 @@
     same => n,Verbose(1, Testing mailbox)
     same => n,VMAuthenticate(9001)
     same => n,UserEvent(TestResult,result: pass,status: Successfully authenticated user)
-    same => n,Wait(5)
     same => n,Hangup()
 
 exten => 9002,1,NoOp()
@@ -25,6 +23,5 @@
     same => n,Verbose(1, Testing mailbox at context)
     same => n,VMAuthenticate(9002 at notdefault)
     same => n,UserEvent(TestResult,result: pass,status: Successfully authenticated user)
-    same => n,Wait(5)
     same => n,Hangup()
 

Modified: asterisk/trunk/tests/apps/voicemail/authenticate_nominal/configs/ast2/extensions.conf
URL: http://svnview.digium.com/svn/testsuite/asterisk/trunk/tests/apps/voicemail/authenticate_nominal/configs/ast2/extensions.conf?view=diff&rev=2177&r1=2176&r2=2177
==============================================================================
--- asterisk/trunk/tests/apps/voicemail/authenticate_nominal/configs/ast2/extensions.conf (original)
+++ asterisk/trunk/tests/apps/voicemail/authenticate_nominal/configs/ast2/extensions.conf Mon Sep 12 10:38:08 2011
@@ -13,9 +13,7 @@
     same => n,Verbose(1, Sending DTMF signal for password)
     same => n,SendDTMF(${PASSWORD})
     same => n,SendDTMF(#)
-    same => n,Wait(5)
-    same => n,UserEvent(TestResult,result: unknown,status: execute next test)
-    same => n,Wait(2)
+    same => n,Wait(1)
     same => n,Hangup()
 
 exten => password,1,NoOp()
@@ -23,8 +21,6 @@
     same => n,Verbose(1, Sending DTMF signal for password)
     same => n,SendDTMF(${PASSWORD})
     same => n,SendDTMF(#)
-    same => n,Wait(5)
-    same => n,UserEvent(TestResult,result: unknown,status: execute next test)
-    same => n,Wait(2)
+    same => n,Wait(1)
     same => n,Hangup()
 

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=2177&r1=2176&r2=2177
==============================================================================
--- asterisk/trunk/tests/apps/voicemail/authenticate_nominal/run-test (original)
+++ asterisk/trunk/tests/apps/voicemail/authenticate_nominal/run-test Mon Sep 12 10:38:08 2011
@@ -33,7 +33,7 @@
         super(AuthenticateNominal, self).__init__()
 
         self.reactor_timeout = 60
-
+        self.senderAmi = None
         self.create_asterisk(2)
 
     def ami_connect(self, ami):
@@ -41,6 +41,7 @@
 
         if not (ami.id == 0):
             self.testCounter = 0
+            self.senderAmi = ami
             self.executeTest(ami)
 
     def executeTest(self, ami):
@@ -85,11 +86,11 @@
             if self.testCounter >= 3:
                 logger.info("All responses received - Stopping Test")
                 self.stop_reactor()
-        else:
-            """ If this is the caller, simply execute the next test """
+
             if self.testCounter < 3:
                 super(AuthenticateNominal, self).reset_timeout()
-                self.executeTest(ami)
+                self.executeTest(self.senderAmi)
+
 
     def run(self):
         super(AuthenticateNominal, self).run()
@@ -99,6 +100,7 @@
 def main():
 
     test = AuthenticateNominal()
+    test.passed = True
 
     test.start_asterisk()
 
@@ -106,7 +108,6 @@
 
     test.stop_asterisk()
 
-    test.passed = True
     for result in test.results:
         test.passed = test.passed and result
 




More information about the asterisk-commits mailing list