Skip to content
Snippets Groups Projects
Commit 8ba5db81 authored by felmer's avatar felmer
Browse files

SSDM-1187: adapt test_multi_data_set_archiving.py to Python 2.6

SVN: 32770
parent 1bdf9aa5
No related branches found
No related tags found
No related merge requests found
......@@ -73,8 +73,11 @@ class TestCase(systemtest.testcase.TestCase):
def extractFromArchive(self, openbisController, tar_file, path_in_tar):
temp_dir = "%s/data/tmp" % (openbisController.installPath)
util.printAndFlush("Extract %s from archive %s" % (path_in_tar, tar_file))
with tarfile.open(tar_file) as tf:
try:
tf = tarfile.open(tar_file)
tf.extract(path_in_tar, temp_dir)
finally:
tf.close()
return "%s/%s" % (temp_dir, path_in_tar)
def calculateMD5(self, file_path):
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment