reading metadata still works if library not installed, closes #304

This commit is contained in:
John Evans 2014-11-21 17:56:52 -05:00
commit 6a59e38aed
8 changed files with 35 additions and 10 deletions

View file

@ -144,7 +144,7 @@ def glymur_config():
lst.append(load_openjpeg_library(libname))
if all(handle is None for handle in lst):
msg = "Neither the openjp2 nor the openjpeg library could be loaded. "
raise IOError(msg)
warnings.warn(msg)
return tuple(lst)
def get_configdir():

View file

@ -17,7 +17,7 @@ import glymur
from . import fixtures
@unittest.skipIf(sys.hexversion < 0x03000000, "do not care about 2.7 here")
@unittest.skipIf(re.match('1|2.0', glymur.version.openjpeg_version),
@unittest.skipIf(re.match('0|1|2.0', glymur.version.openjpeg_version),
"Requires openjpeg 2.1.0 or higher")
class TestPrintingOpenjp2(unittest.TestCase):
"""Tests for verifying how printing works on openjp2 library structures."""