summaryrefslogtreecommitdiff
path: root/pjsip-apps/src/test-pjsua/runall.py
diff options
context:
space:
mode:
Diffstat (limited to 'pjsip-apps/src/test-pjsua/runall.py')
-rw-r--r--pjsip-apps/src/test-pjsua/runall.py21
1 files changed, 21 insertions, 0 deletions
diff --git a/pjsip-apps/src/test-pjsua/runall.py b/pjsip-apps/src/test-pjsua/runall.py
index 41656345..dc1119da 100644
--- a/pjsip-apps/src/test-pjsua/runall.py
+++ b/pjsip-apps/src/test-pjsua/runall.py
@@ -2,6 +2,10 @@
import os
import sys
+# Usage:
+# runall.py [test-to-resume]
+
+
# Initialize test list
tests = []
@@ -28,8 +32,25 @@ for f in os.listdir("scripts-pres"):
for pat in excluded_tests:
tests = [t for t in tests if t.find(pat)==-1]
+# Resume test?
+resume_script=""
+if len(sys.argv) > 1:
+ if sys.argv[1][0]=='-' or sys.argv[1][0]=='/':
+ print "Usage:"
+ print " runall.py [RESUME]"
+ print "where"
+ print " RESUME is string/substring to specify where to resume tests."
+ print " If this argument is omited, tests will start from the beginning."
+ sys.exit(0)
+ resume_script=sys.argv[1]
+
+
# Now run the tests
for t in tests:
+ if resume_script!="" and t.find(resume_script)==-1:
+ print "Skipping " + t +".."
+ continue
+ resume_script=""
cmdline = "python run.py " + t
print "Running " + cmdline
ret = os.system(cmdline + " > output.log")