Merge pull request #1233 from sidheshenator/remove_extra_file_regression

additional files with prefixed imagename removed from result folder
This commit is contained in:
Richard Cordovano 2015-05-08 10:16:10 -04:00
commit 0c3339d2f1

View File

@ -170,6 +170,7 @@ class TestRunner(object):
test_data.printerror = Errors.printerror
# give solr process time to die.
time.sleep(10)
TestRunner._cleanup(test_data)
# This code was causing errors with paths, so its disabled
@ -432,6 +433,30 @@ class TestRunner(object):
theproc.communicate()
antout.close()
def _cleanup(test_data):
"""
Delete the additional files.
:param test_data:
:return:
"""
try:
os.remove(test_data.get_sorted_data_path(DBType.OUTPUT))
except:
pass
try:
os.remove(test_data.get_sorted_errors_path(DBType.OUTPUT))
except:
pass
try:
os.remove(test_data.get_db_dump_path(DBType.OUTPUT))
except:
pass
try:
os.remove(test_data.get_run_time_path(DBType.OUTPUT))
except:
pass
class TestData(object):
"""Container for the input and output of a single image.