Changeset 2020

Show
Ignore:
Timestamp:
04/12/12 14:41:22 (14 months ago)
Author:
ksherdy
Message:

Added path variables to test script.

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • trunk/symbol_table/test/run_tests.py

    r2019 r2020  
    77# to generates expected output files for diff.  
    88# 
     9# 1. Use st_test_file_generator.py to generate 'st_test_UNIFORM_*' CSV symbol files.  
     10# 2. Execute test script. 
     11# 3. diff -r 'results' directory against input symbol files. 
     12# 
    913# Ken Herdy 
    1014# April 12, 2012 
    1115# 
    1216#---------------------------------------------------------------------------- 
    13 #  
    14 # Use: 
    15 # 
    16 # 1. Use st_test_file_generator.py to generate 'st_test_UNIFORM_*' CSV symbol files.  
    17 # 2. Execute test script. 
    18 # 3. diff -r 'results' directory against input symbol files. 
    19 # 
    20 #---------------------------------------------------------------------------- 
    21 #  
     17# Edit: 
     18program_dir_path='../src' 
     19test_dir_path='' 
     20rslt_dir_suffix='_rslts' 
    2221 
    2322import sys 
     
    4847                sys.exit() 
    4948 
    50         program = sys.argv[1] 
    51         testfile_root = sys.argv[2] 
    52         (head, tail) = os.path.split(testfile_root) 
    53         outfile_root = head + '_rslts' 
     49        program = os.path.join(program_dir_path,sys.argv[1]) 
     50        testfile_dir = os.path.join(test_dir_path,sys.argv[2]) 
     51        outfile_root = testfile_dir + rslt_dir_suffix #os.path.basename(testfile_dir) + rslt_dir_suffix 
    5452 
    55         for dirname, dirnames, filenames in os.walk(testfile_root): 
     53        for dirname, dirnames, filenames in os.walk(testfile_dir): 
    5654                for filename in filenames: 
    5755                        if filename.startswith('st_test_') and not filename.endswith('.svn-base'):