/[ascend]/trunk/test/test.c
ViewVC logotype

Diff of /trunk/test/test.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 2527 by jpye, Sat Mar 26 04:32:34 2011 UTC revision 2528 by jpye, Fri Jan 20 03:57:39 2012 UTC
# Line 38  Line 38 
38    
39  extern int register_cunit_tests();  extern int register_cunit_tests();
40    
41  extern struct FilePath* ASC_TEST_DIR;  extern char ASC_TEST_PATH[PATH_MAX];
42    
43  /*  /*
44      The following allows the CUnit tests to be run using a standalone executable      The following allows the CUnit tests to be run using a standalone executable
# Line 135  int main(int argc, char* argv[]){ Line 135  int main(int argc, char* argv[]){
135      char suitename[1000];      char suitename[1000];
136      char list = 0;      char list = 0;
137    
138      struct FilePath* test_executable = ospath_new(argv[0]);      struct FilePath *test_executable = ospath_new(argv[0]);
139      ASC_TEST_DIR = ospath_getdir(test_executable); /** Global Variable containing Path information about the test directory */      struct FilePath *test_dir = ospath_getdir(test_executable); /** Global Variable containing Path information about the test directory */
140        ospath_strncpy(test_dir,ASC_TEST_PATH,PATH_MAX);
141        ospath_free(test_dir);
142        ospath_free(test_executable);
143    
144      static struct option long_options[] = {      static struct option long_options[] = {
145          {"on-error",   required_argument, 0, 'e'},          {"on-error",   required_argument, 0, 'e'},
# Line 248  int main(int argc, char* argv[]){ Line 251  int main(int argc, char* argv[]){
251  cleanup:  cleanup:
252      if(mode == CU_BRM_VERBOSE)ascshutdown("Testing completed.");/* shut down memory manager */      if(mode == CU_BRM_VERBOSE)ascshutdown("Testing completed.");/* shut down memory manager */
253      CU_cleanup_registry();      CU_cleanup_registry();
     ospath_free(test_executable);  
     ospath_free(ASC_TEST_DIR);  
254      return result;      return result;
255  }  }

Legend:
Removed from v.2527  
changed lines
  Added in v.2528

john.pye@anu.edu.au
ViewVC Help
Powered by ViewVC 1.1.22