mirror of https://github.com/CIRCL/PyCIRCLean
Fix process_dir bug in filecheck tests
parent
bfa257534a
commit
c6ecc5e3a3
|
@ -576,7 +576,7 @@ class KittenGroomerFileCheck(KittenGroomerBase):
|
|||
self.process_file(srcpath, dstpath, relative_path)
|
||||
|
||||
def run(self):
|
||||
self.process_dir(self.src_root_dir, self.src_dst_dir)
|
||||
self.process_dir(self.src_root_dir, self.dst_root_dir)
|
||||
|
||||
|
||||
def main(kg_implementation, description):
|
||||
|
|
|
@ -60,7 +60,7 @@ class FileBase(object):
|
|||
else:
|
||||
try:
|
||||
mt = magic.from_file(self.src_path, mime=True)
|
||||
# magic will always return something, even if it's just 'data'
|
||||
# note: magic will always return something, even if it's just 'data'
|
||||
except UnicodeEncodeError as e:
|
||||
# FIXME: The encoding of the file is broken (possibly UTF-16)
|
||||
mt = ''
|
||||
|
|
|
@ -33,13 +33,13 @@ class TestIntegration:
|
|||
|
||||
def test_filecheck(self, src_invalid, dst):
|
||||
groomer = KittenGroomerFileCheck(src_invalid, dst, debug=True)
|
||||
groomer.processdir()
|
||||
groomer.run()
|
||||
test_description = "filecheck_invalid"
|
||||
save_logs(groomer, test_description)
|
||||
|
||||
def test_filecheck_2(self, src_valid, dst):
|
||||
groomer = KittenGroomerFileCheck(src_valid, dst, debug=True)
|
||||
groomer.processdir()
|
||||
groomer.run()
|
||||
test_description = "filecheck_valid"
|
||||
save_logs(groomer, test_description)
|
||||
|
||||
|
|
Loading…
Reference in New Issue