[svn-commits] pabelanger: branch pabelanger/localhostBindaddr r916 - in /asterisk/team/pabe...

SVN commits to the Digium repositories svn-commits at lists.digium.com
Mon Nov 22 21:38:02 CST 2010


Author: pabelanger
Date: Mon Nov 22 21:37:58 2010
New Revision: 916

URL: http://svnview.digium.com/svn/testsuite?view=rev&rev=916
Log:
First round of changes, standardize location of configs.

Added:
    asterisk/team/pabelanger/localhostBindaddr/tests/blind-transfer-parkingtimeout/configs/ast1/
    asterisk/team/pabelanger/localhostBindaddr/tests/blind-transfer-parkingtimeout/configs/ast1/extensions.conf
      - copied unchanged from r915, asterisk/team/pabelanger/localhostBindaddr/tests/blind-transfer-parkingtimeout/configs/extensions.conf
    asterisk/team/pabelanger/localhostBindaddr/tests/blind-transfer-parkingtimeout/configs/ast1/features.conf
      - copied unchanged from r915, asterisk/team/pabelanger/localhostBindaddr/tests/blind-transfer-parkingtimeout/configs/features.conf
    asterisk/team/pabelanger/localhostBindaddr/tests/blind-transfer-parkingtimeout/configs/ast1/iax.conf
      - copied unchanged from r915, asterisk/team/pabelanger/localhostBindaddr/tests/blind-transfer-parkingtimeout/configs/iax.conf
    asterisk/team/pabelanger/localhostBindaddr/tests/blind-transfer-parkingtimeout/configs/ast2/
    asterisk/team/pabelanger/localhostBindaddr/tests/blind-transfer-parkingtimeout/configs/ast2/extensions.conf
      - copied unchanged from r915, asterisk/team/pabelanger/localhostBindaddr/tests/blind-transfer-parkingtimeout/configs2/extensions.conf
    asterisk/team/pabelanger/localhostBindaddr/tests/blind-transfer-parkingtimeout/configs/ast2/iax.conf
      - copied unchanged from r915, asterisk/team/pabelanger/localhostBindaddr/tests/blind-transfer-parkingtimeout/configs2/iax.conf
    asterisk/team/pabelanger/localhostBindaddr/tests/callparking/configs/ast1/
    asterisk/team/pabelanger/localhostBindaddr/tests/callparking/configs/ast1/extensions.conf
      - copied unchanged from r915, asterisk/team/pabelanger/localhostBindaddr/tests/callparking/configs/extensions.conf
    asterisk/team/pabelanger/localhostBindaddr/tests/callparking/configs/ast1/iax.conf
      - copied unchanged from r915, asterisk/team/pabelanger/localhostBindaddr/tests/callparking/configs/iax.conf
    asterisk/team/pabelanger/localhostBindaddr/tests/callparking/configs/ast2/
    asterisk/team/pabelanger/localhostBindaddr/tests/callparking/configs/ast2/extensions.conf
      - copied unchanged from r915, asterisk/team/pabelanger/localhostBindaddr/tests/callparking/configs2/extensions.conf
    asterisk/team/pabelanger/localhostBindaddr/tests/callparking/configs/ast2/iax.conf
      - copied unchanged from r915, asterisk/team/pabelanger/localhostBindaddr/tests/callparking/configs2/iax.conf
    asterisk/team/pabelanger/localhostBindaddr/tests/callparking/configs/ast3/
    asterisk/team/pabelanger/localhostBindaddr/tests/callparking/configs/ast3/extensions.conf
      - copied unchanged from r915, asterisk/team/pabelanger/localhostBindaddr/tests/callparking/configs3/extensions.conf
    asterisk/team/pabelanger/localhostBindaddr/tests/callparking/configs/ast3/iax.conf
      - copied unchanged from r915, asterisk/team/pabelanger/localhostBindaddr/tests/callparking/configs3/iax.conf
    asterisk/team/pabelanger/localhostBindaddr/tests/chanspy/chanspy_barge/configs/ast1/
    asterisk/team/pabelanger/localhostBindaddr/tests/chanspy/chanspy_barge/configs/ast1/extensions.conf
      - copied unchanged from r915, asterisk/team/pabelanger/localhostBindaddr/tests/chanspy/chanspy_barge/configs/extensions.conf
    asterisk/team/pabelanger/localhostBindaddr/tests/chanspy/chanspy_barge/configs/ast1/manager.conf
      - copied unchanged from r915, asterisk/team/pabelanger/localhostBindaddr/tests/chanspy/chanspy_barge/configs/manager.conf
    asterisk/team/pabelanger/localhostBindaddr/tests/chanspy/chanspy_barge/configs/ast1/sip.conf
      - copied unchanged from r915, asterisk/team/pabelanger/localhostBindaddr/tests/chanspy/chanspy_barge/configs/sip.conf
    asterisk/team/pabelanger/localhostBindaddr/tests/chanspy/chanspy_w_mixmonitor/configs/ast1/
    asterisk/team/pabelanger/localhostBindaddr/tests/chanspy/chanspy_w_mixmonitor/configs/ast1/extensions.conf
      - copied unchanged from r915, asterisk/team/pabelanger/localhostBindaddr/tests/chanspy/chanspy_w_mixmonitor/configs/extensions.conf
    asterisk/team/pabelanger/localhostBindaddr/tests/chanspy/chanspy_w_mixmonitor/configs/ast1/manager.conf
      - copied unchanged from r915, asterisk/team/pabelanger/localhostBindaddr/tests/chanspy/chanspy_w_mixmonitor/configs/manager.conf
    asterisk/team/pabelanger/localhostBindaddr/tests/chanspy/chanspy_w_mixmonitor/configs/ast1/sip.conf
      - copied unchanged from r915, asterisk/team/pabelanger/localhostBindaddr/tests/chanspy/chanspy_w_mixmonitor/configs/sip.conf
Removed:
    asterisk/team/pabelanger/localhostBindaddr/tests/blind-transfer-parkingtimeout/configs/extensions.conf
    asterisk/team/pabelanger/localhostBindaddr/tests/blind-transfer-parkingtimeout/configs/features.conf
    asterisk/team/pabelanger/localhostBindaddr/tests/blind-transfer-parkingtimeout/configs/iax.conf
    asterisk/team/pabelanger/localhostBindaddr/tests/blind-transfer-parkingtimeout/configs2/
    asterisk/team/pabelanger/localhostBindaddr/tests/callparking/configs/extensions.conf
    asterisk/team/pabelanger/localhostBindaddr/tests/callparking/configs/iax.conf
    asterisk/team/pabelanger/localhostBindaddr/tests/callparking/configs2/
    asterisk/team/pabelanger/localhostBindaddr/tests/callparking/configs3/
    asterisk/team/pabelanger/localhostBindaddr/tests/chanspy/chanspy_barge/configs/extensions.conf
    asterisk/team/pabelanger/localhostBindaddr/tests/chanspy/chanspy_barge/configs/manager.conf
    asterisk/team/pabelanger/localhostBindaddr/tests/chanspy/chanspy_barge/configs/sip.conf
    asterisk/team/pabelanger/localhostBindaddr/tests/chanspy/chanspy_w_mixmonitor/configs/extensions.conf
    asterisk/team/pabelanger/localhostBindaddr/tests/chanspy/chanspy_w_mixmonitor/configs/manager.conf
    asterisk/team/pabelanger/localhostBindaddr/tests/chanspy/chanspy_w_mixmonitor/configs/sip.conf
Modified:
    asterisk/team/pabelanger/localhostBindaddr/tests/blind-transfer-parkingtimeout/run-test
    asterisk/team/pabelanger/localhostBindaddr/tests/callparking/run-test
    asterisk/team/pabelanger/localhostBindaddr/tests/chanspy/chanspy_barge/run-test
    asterisk/team/pabelanger/localhostBindaddr/tests/chanspy/chanspy_w_mixmonitor/run-test

Modified: asterisk/team/pabelanger/localhostBindaddr/tests/blind-transfer-parkingtimeout/run-test
URL: http://svnview.digium.com/svn/testsuite/asterisk/team/pabelanger/localhostBindaddr/tests/blind-transfer-parkingtimeout/run-test?view=diff&rev=916&r1=915&r2=916
==============================================================================
--- asterisk/team/pabelanger/localhostBindaddr/tests/blind-transfer-parkingtimeout/run-test (original)
+++ asterisk/team/pabelanger/localhostBindaddr/tests/blind-transfer-parkingtimeout/run-test Mon Nov 22 21:37:58 2010
@@ -19,6 +19,8 @@
 from asterisk.asterisk import Asterisk
 from asterisk.version import AsteriskVersion
 
+workingdir = "/tmp/asterisk-testsuite/blind-transfer-parkingtimeout"
+testdir = "tests/blind-transfer-parkingtimeout"
 
 class BlindTransferTest:
     def __init__(self, argv):
@@ -42,16 +44,11 @@
 
         reactor.callWhenRunning(self.run)
 
-        print self.ast_version
-        self.asterisk1 = Asterisk(
-         base="/tmp/asterisk-testsuite/blind-transfer-parkingtimeout")
-        self.asterisk1.install_configs(
-         "tests/blind-transfer-parkingtimeout/configs")
+        self.ast1 = Asterisk(base=workingDir)
+        self.ast1.install_configs("%s/configs/ast1" % (testdir))
 
-        self.asterisk2 = Asterisk(
-         base="/tmp/asterisk-testsuite/blind-transfer-parkingtimeout")
-        self.asterisk2.install_configs(
-         "tests/blind-transfer-parkingtimeout/configs2")
+        self.ast2 = Asterisk(base=workingDir)
+        self.ast2.install_configs("%s/configs/ast2" % (testdir))
 
    # This gets invoked by the dialplan when test succeeds.
     def get_result_b(self, agi):
@@ -67,12 +64,12 @@
         self.log_last_step("Reading results")
 
         # get lock output in case of deadlock before tearing down.
-        self.asterisk1.cli_exec("core show locks")
-        self.asterisk2.cli_exec("core show locks")
+        self.ast1.cli_exec("core show locks")
+        self.ast2.cli_exec("core show locks")
 
         # if channels are still up for some reason, we want to know that
-        self.asterisk1.cli_exec("core show channels")
-        self.asterisk2.cli_exec("core show channels")
+        self.ast1.cli_exec("core show channels")
+        self.ast2.cli_exec("core show channels")
 
         if (self.passed):
             self.log_last_step("Test Passed...")
@@ -91,17 +88,17 @@
     # 4.  B reports results to FastAGI and hangup
     def launch_test(self):
         self.log_last_step("Originating call to begin test")
-        self.asterisk1.cli_originate(
+        self.ast1.cli_originate(
          "IAX2/userA at 127.0.0.1:4571/b_exten extension a_dials at parking")
 
     def start_asterisk(self):
         self.log_last_step("Starting Asterisk")
-        self.asterisk1.start()
-        self.asterisk2.start()
+        self.ast1.start()
+        self.ast2.start()
 
     def stop_asterisk(self):
-        self.asterisk1.stop()
-        self.asterisk2.stop()
+        self.ast1.stop()
+        self.ast2.stop()
 
     def log_last_step(self, step):
         print step

Modified: asterisk/team/pabelanger/localhostBindaddr/tests/callparking/run-test
URL: http://svnview.digium.com/svn/testsuite/asterisk/team/pabelanger/localhostBindaddr/tests/callparking/run-test?view=diff&rev=916&r1=915&r2=916
==============================================================================
--- asterisk/team/pabelanger/localhostBindaddr/tests/callparking/run-test (original)
+++ asterisk/team/pabelanger/localhostBindaddr/tests/callparking/run-test Mon Nov 22 21:37:58 2010
@@ -18,6 +18,9 @@
 sys.path.append("lib/python")
 from asterisk.asterisk import Asterisk
 from asterisk.version import AsteriskVersion
+
+workingdir = "/tmp/asterisk-testsuite/callparking"
+testdir = "tests/callparking"
 
 
 class CallParkingTest:
@@ -54,24 +57,21 @@
 
         reactor.callWhenRunning(self.run)
 
-        self.asterisk1 = Asterisk(
-         base="/tmp/asterisk-testsuite/callparking/asterisk1")
-        self.asterisk1.install_configs("tests/callparking/configs")
+        self.ast1 = Asterisk(base=workingdir)
+        self.ast1.install_configs("%s/configs/ast1" % (testdir))
 
-        self.asterisk2 = Asterisk(
-         base="/tmp/asterisk-testsuite/callparking/asterisk2")
-        self.asterisk2.install_configs("tests/callparking/configs2")
+        self.ast2 = Asterisk(base=workingdir)
+        self.ast2.install_configs("%s/configs/ast2" % (testdir))
 
-        self.asterisk3 = Asterisk(
-         base="/tmp/asterisk-testsuite/callparking/asterisk3")
-        self.asterisk3.install_configs("tests/callparking/configs3")
+        self.ast3 = Asterisk(base=workingdir)
+        self.ast3.install_configs("%s/configs/ast3" % (testdir))
 
     # This gets invoked by the dialplan when userB has parked userA to 701.
     # Initiate new call userB <--> userC now.
     def get_result_b(self, agi):
         self.log_last_step("got AGI connection from userB. "
          "Initiate new call between userB and userC now")
-        self.asterisk1.cli_originate(
+        self.ast1.cli_originate(
          "IAX2/userB at 127.0.0.1:4572/c_exten extension bridge_to_B at parking")
         return agi.finish()
 
@@ -80,7 +80,7 @@
     def get_result_c(self, agi):
         self.log_last_step("got AGI connection from userC. "
          "Now retrieve userA -> call 701")
-        self.asterisk3.cli_originate(
+        self.ast3.cli_originate(
          "IAX2/userA at 127.0.0.1:4570/701 extension retrieve_A at parking")
         return agi.finish()
 
@@ -89,7 +89,7 @@
     def get_result_retrieve_A(self, agi):
         self.log_last_step("got AGI connection from userC. "
          "userA retrieved successfully, now retrieve userB")
-        self.asterisk3.cli_originate(
+        self.ast3.cli_originate(
          "IAX2/userA at 127.0.0.1:4570/702 extension retrieve_B at parking")
         return agi.finish()
 
@@ -110,14 +110,14 @@
         self.log_last_step("Reading results")
 
         # get lock output in case of deadlock before tearing down.
-        self.asterisk1.cli_exec("core show locks")
-        self.asterisk2.cli_exec("core show locks")
-        self.asterisk3.cli_exec("core show locks")
+        self.ast1.cli_exec("core show locks")
+        self.ast2.cli_exec("core show locks")
+        self.ast3.cli_exec("core show locks")
 
         # if channels are still up for some reason, we want to know that
-        self.asterisk1.cli_exec("core show channels")
-        self.asterisk2.cli_exec("core show channels")
-        self.asterisk3.cli_exec("core show channels")
+        self.ast1.cli_exec("core show channels")
+        self.ast2.cli_exec("core show channels")
+        self.ast3.cli_exec("core show channels")
 
         if (self.passed):
             self.log_last_step("Test Passed...")
@@ -139,19 +139,19 @@
 
     def launch_test(self):
         self.log_last_step("Originating call to begin test")
-        self.asterisk1.cli_originate(
+        self.ast1.cli_originate(
          "IAX2/userA at 127.0.0.1:4571/b_exten extension bridge_to_A at parking")
 
     def start_asterisk(self):
         self.log_last_step("Starting Asterisk")
-        self.asterisk1.start()
-        self.asterisk2.start()
-        self.asterisk3.start()
+        self.ast1.start()
+        self.ast2.start()
+        self.ast3.start()
 
     def stop_asterisk(self):
-        self.asterisk1.stop()
-        self.asterisk2.stop()
-        self.asterisk3.stop()
+        self.ast1.stop()
+        self.ast2.stop()
+        self.ast3.stop()
 
     def log_last_step(self, step):
         print step

Modified: asterisk/team/pabelanger/localhostBindaddr/tests/chanspy/chanspy_barge/run-test
URL: http://svnview.digium.com/svn/testsuite/asterisk/team/pabelanger/localhostBindaddr/tests/chanspy/chanspy_barge/run-test?view=diff&rev=916&r1=915&r2=916
==============================================================================
--- asterisk/team/pabelanger/localhostBindaddr/tests/chanspy/chanspy_barge/run-test (original)
+++ asterisk/team/pabelanger/localhostBindaddr/tests/chanspy/chanspy_barge/run-test Mon Nov 22 21:37:58 2010
@@ -20,6 +20,9 @@
 sys.path.append("lib/python")
 from asterisk.asterisk import Asterisk
 from asterisk.version import AsteriskVersion
+
+workingdir = "/tmp/asterisk-testsuite/chanspy/chanspy_barge"
+testdir = "tests/chanspy/chanspy_barge"
 
 class ChanSpyBarge:
     def __init__(self, argv):
@@ -47,11 +50,10 @@
             "transmit_silence" : "yes",
         }
 
-        self.asterisk = Asterisk(base="/tmp/asterisk-testsuite/chanspy/chanspy_barge",
-            ast_conf_options=ast_conf_options)
-        self.asterisk.install_configs("tests/chanspy/chanspy_barge/configs")
-        self.talkingaudio = os.path.join(os.getcwd(), "tests/chanspy/chanspy_barge/sounds/talking")
-        self.audiofile1 = os.path.join(os.getcwd(), "tests/chanspy/chanspy_barge/testaudio1")
+        self.ast1 = Asterisk(base=workingdir, ast_conf_options=ast_conf_options)
+        self.ast1.install_configs("%s/configs/ast1" % (testdir))
+        self.talkingaudio = os.path.join(os.getcwd(), "%s/sounds/talking" % (testdir))
+        self.audiofile1 = os.path.join(os.getcwd(), "%s/testaudio1" % (testdir))
 
     def reportPassed(self, agi):
         print "GOT PASS RESULTS!!!\n"
@@ -64,13 +66,13 @@
 
     def readResult(self):
         self.logLastStep("Reading results")
-        self.asterisk.cli_exec("core show locks")   # get lock output in case of deadlock before tearing down.
-        self.asterisk.cli_exec("core show channels")# if channels are still up for some reason, we want to know that as well
+        self.ast1.cli_exec("core show locks")   # get lock output in case of deadlock before tearing down.
+        self.ast1.cli_exec("core show channels")# if channels are still up for some reason, we want to know that as well
 
         if self.ast_version < AsteriskVersion("1.6.1"):
-            self.asterisk.cli_exec("core show globals") # The global variables here hold failure conditions
+            self.ast1.cli_exec("core show globals") # The global variables here hold failure conditions
         else:
-            self.asterisk.cli_exec("dialplan show globals") # The global variables here hold failure conditions
+            self.ast1.cli_exec("dialplan show globals") # The global variables here hold failure conditions
 
         if self.passed == True:
             print 'SIP ChanSpy test PASSED!'
@@ -116,21 +118,21 @@
 
     def startProcesses(self):
         self.logLastStep("Starting Processes")
-        self.asterisk.start()
+        self.ast1.start()
         playfilearg = "--play-file=%s.wav" % (self.talkingaudio)
         self.pja = subprocess.Popen(['pjsua', '--local-port=5065', '--auto-answer=200', '--null-audio', '--auto-loop'], stdin=subprocess.PIPE, stdout=subprocess.PIPE)
         self.pjb = subprocess.Popen(['pjsua', '--local-port=5066', '--auto-answer=200', playfilearg, '--auto-play'], stdin=subprocess.PIPE, stdout=subprocess.PIPE)
 
         if self.ast_version < AsteriskVersion("1.6.1"):
-            self.asterisk.cli_exec("core set global TESTAUDIO1 " + self.audiofile1)
-            self.asterisk.cli_exec("core set global TALK_AUDIO " + self.talkingaudio)
+            self.ast1.cli_exec("core set global TESTAUDIO1 " + self.audiofile1)
+            self.ast1.cli_exec("core set global TALK_AUDIO " + self.talkingaudio)
         else:
-            self.asterisk.cli_exec("dialplan set global TESTAUDIO1 " + self.audiofile1)
-            self.asterisk.cli_exec("dialplan set global TALK_AUDIO " + self.talkingaudio)
+            self.ast1.cli_exec("dialplan set global TESTAUDIO1 " + self.audiofile1)
+            self.ast1.cli_exec("dialplan set global TALK_AUDIO " + self.talkingaudio)
 
     def stopProcesses(self):
         self.logLastStep("Stopping Processes")
-        self.asterisk.stop()
+        self.ast1.stop()
         os.kill(self.pja.pid, signal.SIGKILL)
         os.kill(self.pjb.pid, signal.SIGKILL)
 
@@ -141,15 +143,15 @@
     def callChanSpy(self):
         self.logLastStep("Placing call to ChanSpy extension.")
         if self.ast_version < AsteriskVersion("1.6.2"):
-            self.asterisk.cli_exec("originate SIP/end_b extension chanspytest at test")
+            self.ast1.cli_exec("originate SIP/end_b extension chanspytest at test")
         else:
-            self.asterisk.cli_exec("channel originate SIP/end_b extension chanspytest at test")
+            self.ast1.cli_exec("channel originate SIP/end_b extension chanspytest at test")
 
     def verifyAudio(self):
         if self.ast_version < AsteriskVersion("1.6.2"):
-            self.asterisk.cli_exec("originate Local/play_recording at test extension detect_audio at test")
+            self.ast1.cli_exec("originate Local/play_recording at test extension detect_audio at test")
         else:
-            self.asterisk.cli_exec("channel originate Local/play_recording at test extension detect_audio at test")
+            self.ast1.cli_exec("channel originate Local/play_recording at test extension detect_audio at test")
 
     def run(self):
 

Modified: asterisk/team/pabelanger/localhostBindaddr/tests/chanspy/chanspy_w_mixmonitor/run-test
URL: http://svnview.digium.com/svn/testsuite/asterisk/team/pabelanger/localhostBindaddr/tests/chanspy/chanspy_w_mixmonitor/run-test?view=diff&rev=916&r1=915&r2=916
==============================================================================
--- asterisk/team/pabelanger/localhostBindaddr/tests/chanspy/chanspy_w_mixmonitor/run-test (original)
+++ asterisk/team/pabelanger/localhostBindaddr/tests/chanspy/chanspy_w_mixmonitor/run-test Mon Nov 22 21:37:58 2010
@@ -21,6 +21,10 @@
 from asterisk.asterisk import Asterisk
 from asterisk.version import AsteriskVersion
 
+workingdir = "/tmp/asterisk-testsuite/chanspy/chanspy_w_mixmonitor"
+testdir = "tests/chanspy/chanspy_w_mixmonitor"
+
+
 class ChanSpyMixMonitorTest:
     def __init__(self, argv):
         self.last_step = ""
@@ -42,10 +46,10 @@
         reactor.listenTCP(4573, self.agi, self.test_to, '127.0.0.1')
 
         print self.ast_version
-        self.asterisk = Asterisk(base="/tmp/asterisk-testsuite/chanspy/chanspy_w_mixmonitor")
-        self.asterisk.install_configs("tests/chanspy/chanspy_w_mixmonitor/configs")
-        self.talkingaudio = os.path.join(os.getcwd(), "tests/chanspy/chanspy_w_mixmonitor/sounds/talking")
-        self.audiofile1 = os.path.join(os.getcwd(), "tests/chanspy/chanspy_w_mixmonitor/testaudio1")
+        self.ast1 = Asterisk(base=workingdir)
+        self.ast1.install_configs("%s/configs" % (testdir))
+        self.talkingaudio = os.path.join(os.getcwd(), "%s/sounds/talking" % (testdir))
+        self.audiofile1 = os.path.join(os.getcwd(), "%s/testaudio1" % (testdir))
 
     def reportPassed(self, agi):
         print "GOT PASS RESULTS!!!\n"
@@ -58,13 +62,13 @@
 
     def readResult(self):
         self.logLastStep("Reading results")
-        self.asterisk.cli_exec("core show locks")   # get lock output in case of deadlock before tearing down.
-        self.asterisk.cli_exec("core show channels")# if channels are still up for some reason, we want to know that as well
+        self.ast1.cli_exec("core show locks")   # get lock output in case of deadlock before tearing down.
+        self.ast1.cli_exec("core show channels")# if channels are still up for some reason, we want to know that as well
 
         if self.ast_version < AsteriskVersion("1.6.1"):
-            self.asterisk.cli_exec("core show globals") # The global variables here hold failure conditions
+            self.ast1.cli_exec("core show globals") # The global variables here hold failure conditions
         else:
-            self.asterisk.cli_exec("dialplan show globals") # The global variables here hold failure conditions
+            self.ast1.cli_exec("dialplan show globals") # The global variables here hold failure conditions
 
         if self.passed == True:
             print 'SIP ChanSpy test PASSED!'
@@ -122,21 +126,21 @@
 
     def startProcesses(self):
         self.logLastStep("Starting Processes")
-        self.asterisk.start()
+        self.ast1.start()
         self.pja = subprocess.Popen(['pjsua', '--local-port=5065', '--auto-answer=200', '--null-audio'], stdin=subprocess.PIPE, stdout=subprocess.PIPE)
         self.pjb = subprocess.Popen(['pjsua', '--local-port=5066', '--auto-answer=200', '--null-audio'], stdin=subprocess.PIPE, stdout=subprocess.PIPE)
         self.pjc = subprocess.Popen(['pjsua', '--local-port=5067', '--auto-answer=200', '--null-audio'], stdin=subprocess.PIPE, stdout=subprocess.PIPE)
 
         if self.ast_version < AsteriskVersion("1.6.1"):
-            self.asterisk.cli_exec("core set global TESTAUDIO1 " + self.audiofile1)
-            self.asterisk.cli_exec("core set global TALK_AUDIO " + self.talkingaudio)
+            self.ast1.cli_exec("core set global TESTAUDIO1 " + self.audiofile1)
+            self.ast1.cli_exec("core set global TALK_AUDIO " + self.talkingaudio)
         else:
-            self.asterisk.cli_exec("dialplan set global TESTAUDIO1 " + self.audiofile1)
-            self.asterisk.cli_exec("dialplan set global TALK_AUDIO " + self.talkingaudio)
+            self.ast1.cli_exec("dialplan set global TESTAUDIO1 " + self.audiofile1)
+            self.ast1.cli_exec("dialplan set global TALK_AUDIO " + self.talkingaudio)
 
     def stopProcesses(self):
         self.logLastStep("Stopping Processes")
-        self.asterisk.stop()
+        self.ast1.stop()
         os.kill(self.pja.pid, signal.SIGKILL)
         os.kill(self.pjb.pid, signal.SIGKILL)
         os.kill(self.pjc.pid, signal.SIGKILL)
@@ -147,18 +151,18 @@
 
     def callChanSpy(self):
         self.logLastStep("Placing call to ChanSpy extension.")
-        self.asterisk.cli_exec("console dial chanspytest at test")
+        self.ast1.cli_exec("console dial chanspytest at test")
 
     def hangupChanSpy(self):
         self.logLastStep("Hangup ChanSpy.")
-        self.asterisk.cli_exec("console hangup")
+        self.ast1.cli_exec("console hangup")
         reactor.callLater(2, self.verifyAudio)
 
     def verifyAudio(self):
         if self.ast_version < AsteriskVersion("1.6.2"):
-            self.asterisk.cli_exec("originate Local/play_recording at test extension detect_audio at test")
+            self.ast1.cli_exec("originate Local/play_recording at test extension detect_audio at test")
         else:
-            self.asterisk.cli_exec("channel originate Local/play_recording at test extension detect_audio at test")
+            self.ast1.cli_exec("channel originate Local/play_recording at test extension detect_audio at test")
 
     def run(self):
 




More information about the svn-commits mailing list