mirror of
https://github.com/overcuriousity/autopsy-flatpak.git
synced 2025-07-17 10:17:41 +00:00
Merge pull request #1194 from sidheshenator/regression_test_output_tweaks
gold files are easily available in th OP folder in case of diff
This commit is contained in:
commit
9493c3d18b
@ -848,6 +848,12 @@ class TestResultsDiffer(object):
|
|||||||
dffcmdlst = ["diff", output_file, gold_file]
|
dffcmdlst = ["diff", output_file, gold_file]
|
||||||
subprocess.call(dffcmdlst, stdout = diff_file)
|
subprocess.call(dffcmdlst, stdout = diff_file)
|
||||||
Errors.add_errors_out(diff_path)
|
Errors.add_errors_out(diff_path)
|
||||||
|
|
||||||
|
# create file path for gold files inside report output folder. In case of diff, both gold and current run
|
||||||
|
# Exception.txt files are available in the report output folder. Prefix Gold- is added to the filename.
|
||||||
|
gold_file_in_output_dir = output_file[:output_file.rfind("\\")] + "Gold-" + output_file[output_file.rfind("\\")+1:]
|
||||||
|
shutil.copy(gold_file, gold_file_in_output_dir)
|
||||||
|
|
||||||
return False
|
return False
|
||||||
else:
|
else:
|
||||||
return True
|
return True
|
||||||
|
@ -141,6 +141,12 @@ class TskDbDiff(object):
|
|||||||
diff_file = codecs.open(diff_path, "wb", "utf_8")
|
diff_file = codecs.open(diff_path, "wb", "utf_8")
|
||||||
dffcmdlst = ["diff", gold_file, output_file]
|
dffcmdlst = ["diff", gold_file, output_file]
|
||||||
subprocess.call(dffcmdlst, stdout = diff_file)
|
subprocess.call(dffcmdlst, stdout = diff_file)
|
||||||
|
|
||||||
|
# create file path for gold files inside output folder. In case of diff, both gold and current run files
|
||||||
|
# are available in the report output folder. Prefix Gold- is added to the filename.
|
||||||
|
gold_file_in_output_dir = output_file[:output_file.rfind("/")] + "/Gold-" + output_file[output_file.rfind("/")+1:]
|
||||||
|
shutil.copy(gold_file, gold_file_in_output_dir)
|
||||||
|
|
||||||
return False
|
return False
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user