fix_old_run_status(test_run)
# end if

if test_run.update_db :
    # load the DB with the pre-execution test case info
    upload_initial_db_info(test_run)
# end if

# execute each test case
execute_test_cases(test_run)

# update the database with the test run results
finalize_test_run_status(test_run)

# print final results to screen and file
print_result_summary(test_run)

# do cleanup
if test_run.update_db :
    test_run.close_db_connection()
# end if

# move output files
archive_output_files(test_run)

# exit
print ""
print "harness return code is %d" % (harness_return_code)
print ""
sys.exit(harness_return_code)
    fix_old_run_status(test_run)
# end if

if test_run.update_db:
    # load the DB with the pre-execution test case info
    upload_initial_db_info(test_run)
# end if

# execute each test case
execute_test_cases(test_run)

# update the database with the test run results
finalize_test_run_status(test_run)

# print final results to screen and file
print_result_summary(test_run)

# do cleanup
if test_run.update_db:
    test_run.close_db_connection()
# end if

# move output files
archive_output_files(test_run)

# exit
print ""
print "harness return code is %d" % (harness_return_code)
print ""
sys.exit(harness_return_code)