apr-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jor...@apache.org
Subject cvs commit: apr/test abts.c
Date Mon, 24 May 2004 12:45:29 GMT
jorton      2004/05/24 05:45:29

  Modified:    test     abts.c
  Log:
  * test/abts.c (abts_add_suite): Strip .c extension from subsuite name.
  
  Revision  Changes    Path
  1.6       +8 -3      apr/test/abts.c
  
  Index: abts.c
  ===================================================================
  RCS file: /home/cvs/apr/test/abts.c,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -d -u -r1.5 -r1.6
  --- abts.c	24 May 2004 09:19:02 -0000	1.5
  +++ abts.c	24 May 2004 12:45:29 -0000	1.6
  @@ -89,6 +89,7 @@
   {
       sub_suite *subsuite;
       curr_char = 0;
  +    char *p;
       
       /* Only end the suite if we actually ran it */
       if (suite && suite->tail &&!suite->tail->not_run) {
  @@ -99,7 +100,11 @@
       subsuite->num_test = 0;
       subsuite->failed = 0;
       subsuite->next = NULL;
  -    subsuite->name = suite_name;
  +    p = strchr(suite_name, '.');
  +    if (p)
  +        subsuite->name = strndup(suite_name, p - suite_name);
  +    else
  +        subsuite->name = suite_name;
       subsuite->not_run = 0;
   
       if (suite == NULL) {
  @@ -112,13 +117,13 @@
           suite->tail = subsuite;
       }
   
  -    if (!should_test_run(suite_name)) {
  +    if (!should_test_run(subsuite->name)) {
           subsuite->not_run = 1;
           return suite;
       }
   
       reset_status();
  -    fprintf(stdout, "%s:  ", suite_name);
  +    fprintf(stdout, "%s:  ", subsuite->name);
       update_status();
       fflush(stdout);
   
  
  
  

Mime
View raw message