diff options
| -rw-r--r-- | MAT/archive.py | 4 | ||||
| -rw-r--r-- | test/test.py | 6 |
2 files changed, 7 insertions, 3 deletions
diff --git a/MAT/archive.py b/MAT/archive.py index 61c85a5..74100a9 100644 --- a/MAT/archive.py +++ b/MAT/archive.py | |||
| @@ -160,8 +160,8 @@ class TarStripper(GenericArchiveStripper): | |||
| 160 | return current_file | 160 | return current_file |
| 161 | 161 | ||
| 162 | def remove_all(self): | 162 | def remove_all(self): |
| 163 | tarin = tarfile.open(self.filename, 'r' + self.compression) | 163 | tarin = tarfile.open(self.filename, 'r' + self.compression, encoding='utf-8') |
| 164 | tarout = tarfile.open(self.output, 'w' + self.compression) | 164 | tarout = tarfile.open(self.output, 'w' + self.compression, encoding='utf-8') |
| 165 | for item in tarin.getmembers(): | 165 | for item in tarin.getmembers(): |
| 166 | tarin.extract(item, self.tempdir) | 166 | tarin.extract(item, self.tempdir) |
| 167 | name = os.path.join(self.tempdir, item.name) | 167 | name = os.path.join(self.tempdir, item.name) |
diff --git a/test/test.py b/test/test.py index f2970ff..7becd5b 100644 --- a/test/test.py +++ b/test/test.py | |||
| @@ -15,7 +15,7 @@ import tempfile | |||
| 15 | import unittest | 15 | import unittest |
| 16 | import subprocess | 16 | import subprocess |
| 17 | 17 | ||
| 18 | VERBOSITY = 5 | 18 | VERBOSITY = 15 |
| 19 | 19 | ||
| 20 | clean = glob.glob('clean*') | 20 | clean = glob.glob('clean*') |
| 21 | clean.sort() | 21 | clean.sort() |
| @@ -43,6 +43,10 @@ try: # file format exclusively managed by exiftool | |||
| 43 | except OSError: | 43 | except OSError: |
| 44 | pass # None for now | 44 | pass # None for now |
| 45 | 45 | ||
| 46 | FILE_LIST.remove(('clean é.pdf', 'dirty é.pdf')) | ||
| 47 | #FILE_LIST.remove(('clean é.tar', 'dirty é.tar')) | ||
| 48 | FILE_LIST.remove(('clean é.tar.gz', 'dirty é.tar.gz')) | ||
| 49 | #FILE_LIST.remove(('clean é.tar.bz2', 'dirty é.tar.bz2')) | ||
| 46 | 50 | ||
| 47 | class MATTest(unittest.TestCase): | 51 | class MATTest(unittest.TestCase): |
| 48 | ''' | 52 | ''' |
