[freeimage tests] Add a test w/ truncated image

This tests tests the fix in the previous commit b9a7445, covering the
issue noted in issue #1037.
This commit is contained in:
Kevin Murray
2014-06-27 21:32:18 +10:00
parent b9a7445296
commit d69cdb951b
2 changed files with 7 additions and 0 deletions
Binary file not shown.

After

Width:  |  Height:  |  Size: 400 B

+7
View File
@@ -37,6 +37,13 @@ def test_imread():
assert img.shape == (370, 371, 3)
assert all(img[274, 135] == [0, 130, 253])
@skipif(not FI_available)
def test_imread_truncated_jpg():
raised = False
raised = True
assert_raises(RuntimeError,
sio.imread,
os.path.join(si.data_dir, 'truncated.jpg'))
@skipif(not FI_available)
def test_imread_uint16():