[Freeswitch-svn] [commit] r12733 - in freeswitch/trunk/libs/sofia-sip: . s2check

FreeSWITCH SVN mikej at freeswitch.org
Tue Mar 24 08:32:49 PDT 2009


Author: mikej
Date: Tue Mar 24 10:32:49 2009
New Revision: 12733

Log:
Thu Mar  5 11:44:15 CST 2009  Pekka Pessi <first.last at nokia.com>
  * s2check.h: redefine tcase_add_loop_test, too
  Ignore-this: 149c19e8d089b60e8ddcb98da54c9d88



Modified:
   freeswitch/trunk/libs/sofia-sip/.update
   freeswitch/trunk/libs/sofia-sip/s2check/s2check.h
   freeswitch/trunk/libs/sofia-sip/s2check/s2tcase.c

Modified: freeswitch/trunk/libs/sofia-sip/.update
==============================================================================
--- freeswitch/trunk/libs/sofia-sip/.update	(original)
+++ freeswitch/trunk/libs/sofia-sip/.update	Tue Mar 24 10:32:49 2009
@@ -1 +1 @@
-Tue Mar 24 10:30:39 CDT 2009
+Tue Mar 24 10:31:53 CDT 2009

Modified: freeswitch/trunk/libs/sofia-sip/s2check/s2check.h
==============================================================================
--- freeswitch/trunk/libs/sofia-sip/s2check/s2check.h	(original)
+++ freeswitch/trunk/libs/sofia-sip/s2check/s2check.h	Tue Mar 24 10:32:49 2009
@@ -42,10 +42,16 @@
 SOFIA_BEGIN_DECLS
 
 #undef tcase_add_test
+#undef tcase_add_loop_test
+
 /* Redirect tcase_add_test() to our function */
-#define tcase_add_test(tc, tf) s2_tcase_add_test(tc, tf, "" #tf "")
+#define tcase_add_test(tc, tf) s2_tcase_add_test(tc, tf, "" #tf "", 0, 0, 1)
+
+void s2_tcase_add_test(TCase *, TFun, char const *name,
+		       int signo, int start, int end);
 
-void s2_tcase_add_test(TCase *, TFun, char const *name);
+#define tcase_add_loop_test(tc, tf, s, e) \
+  s2_tcase_add_test(tc, tf, "" #tf "", 0, (s), (e))
 
 void s2_select_tests(char const *pattern);
 

Modified: freeswitch/trunk/libs/sofia-sip/s2check/s2tcase.c
==============================================================================
--- freeswitch/trunk/libs/sofia-sip/s2check/s2tcase.c	(original)
+++ freeswitch/trunk/libs/sofia-sip/s2check/s2tcase.c	Tue Mar 24 10:32:49 2009
@@ -46,7 +46,8 @@
  * A special version of tcase_add_test() that inserts test function into
  * tcase only if its name matches given pattern.
  */
-void s2_tcase_add_test(TCase *tc, TFun tf, char const *name)
+void s2_tcase_add_test(TCase *tc, TFun tf, char const *name,
+		       int signo, int start, int end)
 {
   char const * const *patterns;
 
@@ -54,9 +55,9 @@
   for (patterns = test_patterns; *patterns; patterns++) {
     if (!fnmatch(*patterns, name, 0)) {
       if (strcmp(*patterns, "*")) {
-	printf("%s: running\n", name);
+	printf("%s: selected\n", name);
       }
-      _tcase_add_test(tc, tf, name, 0, 0, 1);
+      _tcase_add_test(tc, tf, name, signo, start, end);
       return;
     }
   }
@@ -64,9 +65,9 @@
   for (patterns = test_patterns; *patterns; patterns++) {
     if (!strcmp(*patterns, name) || !strcmp(*patterns, "*")) {
       if (strcmp(*patterns, "*")) {
-	printf("%s: running\n", name);
+	printf("%s: selected\n", name);
       }
-      _tcase_add_test(tc, tf, name, 0, 0, 1);
+      _tcase_add_test(tc, tf, name, signo, start, end);
       return;
     }
   }



More information about the Freeswitch-svn mailing list