merge branch 'issue316' into devel

This commit is contained in:
John Evans 2015-01-08 12:08:16 -05:00
commit 1bfb2f5fc8
5 changed files with 19 additions and 19 deletions

View file

@ -39,6 +39,7 @@ from . import fixtures
def docTearDown(doctest_obj): def docTearDown(doctest_obj):
glymur.set_parseoptions(full_codestream=False) glymur.set_parseoptions(full_codestream=False)
# Doc tests should be run as well. # Doc tests should be run as well.
def load_tests(loader, tests, ignore): def load_tests(loader, tests, ignore):
"""Should run doc tests as well""" """Should run doc tests as well"""
@ -1079,9 +1080,6 @@ class TestParsing(unittest.TestCase):
class TestJp2kOpjDataRootWarnings(unittest.TestCase): class TestJp2kOpjDataRootWarnings(unittest.TestCase):
"""These tests should be run by just about all configuration.""" """These tests should be run by just about all configuration."""
def tearDown(self):
glymur.set_parseoptions(full_codestream=False)
def test_undecodeable_box_id(self): def test_undecodeable_box_id(self):
"""Should warn in case of undecodeable box ID but not error out.""" """Should warn in case of undecodeable box ID but not error out."""
filename = opj_data_file('input/nonregression/edf_c2_1013627.jp2') filename = opj_data_file('input/nonregression/edf_c2_1013627.jp2')

View file

@ -1065,12 +1065,14 @@ class TestJp2dump(unittest.TestCase):
expected = '\n'.join(expected) expected = '\n'.join(expected)
self.assertEqual(actual, expected) self.assertEqual(actual, expected)
@unittest.skipIf(sys.hexversion < 0x03000000, "assertRegex not in 2.7")
def test_jp2_codestream_0(self): def test_jp2_codestream_0(self):
"""Verify dumping with -c 0, supressing all codestream details.""" """Verify dumping with -c 0, supressing all codestream details."""
actual = self.run_jp2dump(['', '-c', '0', self.jp2file]) actual = self.run_jp2dump(['', '-c', '0', self.jp2file])
expected = fixtures.nemo_dump_no_codestream # shave off the codestream details
lines = fixtures.nemo.split('\n')
expected = lines[0:105]
expected = '\n'.join(expected)
self.assertEqual(actual, expected) self.assertEqual(actual, expected)
def test_jp2_codestream_1(self): def test_jp2_codestream_1(self):