summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorAdam Hupp <adam@hupp.org>2020-01-24 21:20:11 -0800
committerAdam Hupp <adam@hupp.org>2020-01-24 21:23:05 -0800
commit0e977c98649b4ed4533a7700fbc5fea6895bfe71 (patch)
tree23746920d0aec60d7c7849dbcc494a78c8a09c5f /test
parent2d63bfa6f929857f9f3005b9552517d0f22adc47 (diff)
downloadpython-magic-0e977c98649b4ed4533a7700fbc5fea6895bfe71.tar.gz
Expose magic_version as magic.version(), which returns an integer representing the version number.
re: https://github.com/ahupp/python-magic/issues/204
Diffstat (limited to 'test')
-rwxr-xr-xtest/test.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/test/test.py b/test/test.py
index c6ba522..d067b15 100755
--- a/test/test.py
+++ b/test/test.py
@@ -11,6 +11,9 @@ import sys
class MagicTest(unittest.TestCase):
TESTDATA_DIR = os.path.join(os.path.dirname(os.path.abspath(__file__)), 'testdata')
+ def test_version(self):
+ self.assertTrue(magic.version() > 0)
+
def test_fs_encoding(self):
self.assertEqual('utf-8', sys.getfilesystemencoding().lower())