Pillow/Tests/test_file_fitsstub.py

18 lines
408 B
Python

from helper import unittest, PillowTestCase
from PIL import FitsStubImagePlugin
class TestFileFitsStub(PillowTestCase):
def test_invalid_file(self):
invalid_file = "Tests/images/flower.jpg"
self.assertRaises(SyntaxError,
lambda:
FitsStubImagePlugin.FITSStubImageFile(invalid_file))
if __name__ == '__main__':
unittest.main()