summaryrefslogtreecommitdiff
path: root/test/libtest.py
diff options
context:
space:
mode:
Diffstat (limited to 'test/libtest.py')
-rw-r--r--test/libtest.py8
1 files changed, 5 insertions, 3 deletions
diff --git a/test/libtest.py b/test/libtest.py
index 0b45505..f052b6e 100644
--- a/test/libtest.py
+++ b/test/libtest.py
@@ -99,6 +99,7 @@ class TestSecureRemove(unittest.TestCase):
99 ''' 99 '''
100 self.assertRaises(MAT.exceptions.UnableToRemoveFile, MAT.mat.secure_remove, '/NOTREMOVABLE') 100 self.assertRaises(MAT.exceptions.UnableToRemoveFile, MAT.mat.secure_remove, '/NOTREMOVABLE')
101 101
102
102class TestArchiveProcessing(test.MATTest): 103class TestArchiveProcessing(test.MATTest):
103 ''' Test archives processing 104 ''' Test archives processing
104 ''' 105 '''
@@ -107,7 +108,7 @@ class TestArchiveProcessing(test.MATTest):
107 ''' 108 '''
108 tarpath = os.path.join(self.tmpdir, "test.tar.bz2") 109 tarpath = os.path.join(self.tmpdir, "test.tar.bz2")
109 tar = tarfile.open(tarpath, "w:bz2") 110 tar = tarfile.open(tarpath, "w:bz2")
110 for clean,dirty in self.file_list: 111 for clean, dirty in self.file_list:
111 tar.add(dirty) 112 tar.add(dirty)
112 tar.add(clean) 113 tar.add(clean)
113 tar.close() 114 tar.close()
@@ -121,7 +122,7 @@ class TestArchiveProcessing(test.MATTest):
121 ''' 122 '''
122 tarpath = os.path.join(self.tmpdir, "test.tar") 123 tarpath = os.path.join(self.tmpdir, "test.tar")
123 tar = tarfile.open(tarpath, "w") 124 tar = tarfile.open(tarpath, "w")
124 for clean,dirty in self.file_list: 125 for clean, dirty in self.file_list:
125 tar.add(dirty) 126 tar.add(dirty)
126 tar.add(clean) 127 tar.add(clean)
127 tar.close() 128 tar.close()
@@ -135,7 +136,7 @@ class TestArchiveProcessing(test.MATTest):
135 ''' 136 '''
136 tarpath = os.path.join(self.tmpdir, "test.tar.gz") 137 tarpath = os.path.join(self.tmpdir, "test.tar.gz")
137 tar = tarfile.open(tarpath, "w") 138 tar = tarfile.open(tarpath, "w")
138 for clean,dirty in self.file_list: 139 for clean, dirty in self.file_list:
139 tar.add(dirty) 140 tar.add(dirty)
140 tar.add(clean) 141 tar.add(clean)
141 tar.close() 142 tar.close()
@@ -156,6 +157,7 @@ class TestArchiveProcessing(test.MATTest):
156 unsupported_files = set(current_file.is_clean(list_unsupported=True)) 157 unsupported_files = set(current_file.is_clean(list_unsupported=True))
157 self.assertEqual(unsupported_files, set(('mat.desktop', 'README.security', 'setup.py'))) 158 self.assertEqual(unsupported_files, set(('mat.desktop', 'README.security', 'setup.py')))
158 159
160
159def get_tests(): 161def get_tests():
160 ''' Returns every libtests''' 162 ''' Returns every libtests'''
161 suite = unittest.TestSuite() 163 suite = unittest.TestSuite()