python: fix the test asserting that reading the version succeeded

Signed-off-by: Justus Winter <4winter@informatik.uni-hamburg.de>
This commit is contained in:
Justus Winter 2012-04-29 16:21:32 +02:00
parent 61cf962df8
commit 99b4ae1a88

View file

@ -7,7 +7,8 @@ from distutils.core import setup
version_file = os.path.join(os.path.dirname(__file__),
'notmuch', 'version.py')
exec(compile(open(version_file).read(), version_file, 'exec'))
assert __VERSION__, 'Failed to read the notmuch binding version number'
assert '__VERSION__' in globals(), \
'Failed to read the notmuch binding version number'
setup(name='notmuch',
version=__VERSION__,