summaryrefslogtreecommitdiff
path: root/test/test.py
diff options
context:
space:
mode:
Diffstat (limited to 'test/test.py')
-rwxr-xr-xtest/test.py7
1 files changed, 7 insertions, 0 deletions
diff --git a/test/test.py b/test/test.py
index 6f0f496..15a4115 100755
--- a/test/test.py
+++ b/test/test.py
@@ -111,6 +111,13 @@ class MagicTest(unittest.TestCase):
finally:
del os.environ['TZ']
+ def test_extension(self):
+ m = magic.Magic(extension=True)
+ self.assert_values(m, {
+ 'test.gz': 'gz/tgz/tpz/zabw/svgz',
+ 'name_use.jpg': 'jpeg/jpg/jpe/jfif',
+ })
+
def test_unicode_result_nonraw(self):
m = magic.Magic(raw=False)
src = os.path.join(MagicTest.TESTDATA_DIR, 'pgpunicode')