MCPcopy Index your code
hub / github.com/ahupp/python-magic / test_extension

Method test_extension

test/python_magic_test.py:131–141  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

129 del os.environ['TZ']
130
131 def test_extension(self):
132 try:
133 m = magic.Magic(extension=True)
134 self.assert_values(m, {
135 # some versions return '' for the extensions of a gz file,
136 # including w/ the command line. Who knows...
137 'test.gz': ('gz/tgz/tpz/zabw/svgz', '', '???'),
138 'name_use.jpg': 'jpeg/jpg/jpe/jfif',
139 })
140 except NotImplementedError:
141 self.skipTest('MAGIC_EXTENSION not supported in this version')
142
143 def test_unicode_result_nonraw(self):
144 m = magic.Magic(raw=False)

Callers

nothing calls this directly

Calls 1

assert_valuesMethod · 0.95

Tested by

no test coverage detected