Ticket #543: added mod pesq & mod media playrec to runall.py, also added some more wav files

git-svn-id: https://svn.pjsip.org/repos/pjproject/trunk@2051 74dad513-b988-da41-8d7b-12977e46ad98
diff --git a/pjsip-apps/src/test-pjsua/mod_media_playrec.py b/pjsip-apps/src/test-pjsua/mod_media_playrec.py
index 30f2f6d..2fe260d 100644
--- a/pjsip-apps/src/test-pjsua/mod_media_playrec.py
+++ b/pjsip-apps/src/test-pjsua/mod_media_playrec.py
@@ -21,6 +21,9 @@
 # WAV similarity calculator
 COMPARE_WAV_EXE = "tools/cmp_wav.exe"
 
+# Threshold to declare degradation is too high when result is lower than this value
+COMPARE_THRESHOLD = 2
+
 # UserData
 class mod_media_playrec_user_data:
 	input_filename = ""
@@ -86,10 +89,10 @@
 
 	# Evaluate the similarity value
 	sim_val = mo_sim_val.group(1)
-	if (sim_val > 0):
+	if (sim_val >= COMPARE_THRESHOLD):
 		endpt.trace("WAV similarity = " + sim_val)
 	else:
-		raise TestError("Degraded WAV heavily distorted")
+		raise TestError("WAV degraded heavily, similarity = " + sim_val)
 
 
 # Here where it all comes together
diff --git a/pjsip-apps/src/test-pjsua/runall.py b/pjsip-apps/src/test-pjsua/runall.py
index 11ea592..463e8ad 100644
--- a/pjsip-apps/src/test-pjsua/runall.py
+++ b/pjsip-apps/src/test-pjsua/runall.py
@@ -12,8 +12,10 @@
 # Excluded tests (because they fail?)
 excluded_tests = [ "svn",
 		   "pyc",
-		   #"scripts-call/150_srtp_1_2",
-		   "scripts-call/150_srtp_2_1"
+		   "scripts-call/150_srtp_2_1",				# SRTP optional 'cannot' call SRTP mandatory
+		   "scripts-media-playrec/100_resample_lf_8_11.py",	# related to clock-rate 11 kHz problem
+		   "scripts-media-playrec/100_resample_lf_8_22.py",	# related to clock-rate 22 kHz problem
+		   "scripts-media-playrec/100_resample_lf_11"		# related to clock-rate 11 kHz problem
                    ]
 
 # Add basic tests
@@ -32,6 +34,14 @@
 for f in os.listdir("scripts-sendto"):
     tests.append("mod_sendto.py scripts-sendto/" + f)
 
+# Add mod_media_playrec tests
+for f in os.listdir("scripts-media-playrec"):
+    tests.append("mod_media_playrec.py scripts-media-playrec/" + f)
+
+# Add mod_pesq tests
+for f in os.listdir("scripts-pesq"):
+    tests.append("mod_pesq.py scripts-pesq/" + f)
+
 # Filter-out excluded tests
 for pat in excluded_tests:
     tests = [t for t in tests if t.find(pat)==-1]
diff --git a/pjsip-apps/src/test-pjsua/wavs/input.22.wav b/pjsip-apps/src/test-pjsua/wavs/input.22.wav
new file mode 100644
index 0000000..55fd214
--- /dev/null
+++ b/pjsip-apps/src/test-pjsua/wavs/input.22.wav
Binary files differ
diff --git a/pjsip-apps/src/test-pjsua/wavs/input.32.wav b/pjsip-apps/src/test-pjsua/wavs/input.32.wav
new file mode 100644
index 0000000..2e1b0d2
--- /dev/null
+++ b/pjsip-apps/src/test-pjsua/wavs/input.32.wav
Binary files differ
diff --git a/pjsip-apps/src/test-pjsua/wavs/input.44.wav b/pjsip-apps/src/test-pjsua/wavs/input.44.wav
new file mode 100644
index 0000000..fc46abc
--- /dev/null
+++ b/pjsip-apps/src/test-pjsua/wavs/input.44.wav
Binary files differ
diff --git a/pjsip-apps/src/test-pjsua/wavs/input.48.wav b/pjsip-apps/src/test-pjsua/wavs/input.48.wav
new file mode 100644
index 0000000..4ab8744
--- /dev/null
+++ b/pjsip-apps/src/test-pjsua/wavs/input.48.wav
Binary files differ