Add codec debug tests in pysflphone

This commit is contained in:
Alexandre Savard
2009-05-11 10:34:05 -04:00
parent 8f67a7895d
commit 248a4c9b6b
2 changed files with 23 additions and 4 deletions

View File

@ -7,26 +7,32 @@ class SflPhoneTests(SflPhoneCtrlSimple):
def test_get_allaccounts_methods(self):
print "getAllAccounts()"
print "--- getAllAccounts() ---"
for account in self.getAllAccounts():
print " " + account
print "\n"
print "getAllRegisteredAccounts()"
print "--- getAllRegisteredAccounts() ---"
for account in self.getAllRegisteredAccounts():
print " " + account
print "\n"
print "getAllSipAccounts()"
print "--- getAllSipAccounts() ---"
for account in self.getAllSipAccounts():
print " " + account
print "\n"
print "getAllIaxAccounts()"
print "--- getAllIaxAccounts() ---"
for account in self.getAllIaxAccounts():
print " " + account
print "\n"
def test_codecs_methods
print "--- getCodecList() ---"
for codec int self.getCodecList():
print " " + codec
print "\n"
sfl = SflPhoneTests()

View File

@ -342,6 +342,19 @@ class SflPhoneCtrlSimple(object):
except SflPhoneError, e:
print e
#
# Codec manager
#
def getCodecList(self):
""" Return the codec list """
return self.configurationmanager.getCodecList()
def getActiveCodecList(self):
""" Return the active codec list """
return self.configurationmanager.getActiveCodecList()
#
# Call management