3532: Write Output path to a text file instead of a html file.

This commit is contained in:
U-BASIS\zhaohui 2018-03-21 10:26:14 -04:00
parent bb1be88751
commit d21202e528

View File

@ -83,7 +83,7 @@ AUTOPSY_TEST_CASE = "AutopsyTestCase"
Day = 0 Day = 0
# HTML file name for links of output directories # HTML file name for links of output directories
OUTPUT_DIR_LINK_FILE="output_dir_link.html" OUTPUT_DIR_LINK_FILE="output_dir_link.txt"
def usage(): def usage():
print ("-f PATH single file") print ("-f PATH single file")
@ -878,20 +878,20 @@ class TestConfiguration(object):
os.makedirs(self.output_dir) os.makedirs(self.output_dir)
#write the output_dir to a html file #write the output_dir to a text file
linkFile = open(os.path.join(self.args.diff_files_output_folder, OUTPUT_DIR_LINK_FILE), "a") linkFile = open(os.path.join(self.args.diff_files_output_folder, OUTPUT_DIR_LINK_FILE), "a")
index = self.output_dir.find("\\") index = self.output_dir.find("\\")
linkStr = "<a href=\"file://" linkStr = "file://"
linkOutputDir = self.output_dir[index+2:].replace("//", "/").replace("\\\\", "\\") linkOutputDir = self.output_dir[index+2:].replace("//", "/").replace("\\\\", "\\")
if index == 0: if index == 0:
linkStr = linkStr + linkOutputDir linkStr = linkStr + linkOutputDir
else: else:
linkStr = linkStr + socket.gethostname() + "\\" + linkOutputDir linkStr = linkStr + socket.gethostname() + "\\" + linkOutputDir
if self.testUserCase == "multi": if self.testUserCase == "multi":
linkStr = linkStr + "\">Enterprise Tests</a>" linkStr = "Enterprise Tests: " + linkStr
else: else:
linkStr = linkStr + "\">Standalone Tests</a>" linkStr = "Standalone Tests: " + linkStr
linkFile.write(linkStr + "\n") linkFile.write(linkStr + "\n")
linkFile.close() linkFile.close()