From 83d0717986f66b47ecc323328befdcb50a67fe54 Mon Sep 17 00:00:00 2001 From: Kevin Murray Date: Mon, 30 Jun 2014 18:47:31 +1000 Subject: [PATCH] [test_freeimage] Allow ValueError to be raised With the truncated image, sometimes ValueError is raised. This allows either RuntimeError (i.e. libfreeimage error) or ValueError to be raised. --- skimage/io/tests/test_freeimage.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/skimage/io/tests/test_freeimage.py b/skimage/io/tests/test_freeimage.py index 38ba725f..4e64bd16 100644 --- a/skimage/io/tests/test_freeimage.py +++ b/skimage/io/tests/test_freeimage.py @@ -39,7 +39,7 @@ def test_imread(): @skipif(not FI_available) def test_imread_truncated_jpg(): - assert_raises(RuntimeError, + assert_raises((RuntimeError, ValueError), sio.imread, os.path.join(si.data_dir, 'truncated.jpg'))