mirror of
https://github.com/python-pillow/Pillow.git
synced 2025-01-14 03:21:44 +03:00
commit
0b9d378d17
|
@ -26,8 +26,8 @@ class TestFileCur(PillowTestCase):
|
|||
no_cursors_file = "Tests/images/no_cursors.cur"
|
||||
|
||||
cur = CurImagePlugin.CurImageFile(TEST_FILE)
|
||||
cur.fp = open(no_cursors_file, "rb")
|
||||
self.assertRaises(TypeError, cur._open)
|
||||
with open(no_cursors_file, "rb") as cur.fp:
|
||||
self.assertRaises(TypeError, cur._open)
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
|
|
|
@ -390,7 +390,7 @@ class TestRegistry(PillowTestCase):
|
|||
def test_encode_registry(self):
|
||||
|
||||
Image.register_encoder('MOCK', mock_encode)
|
||||
self.assert_('MOCK' in Image.ENCODERS)
|
||||
self.assertIn('MOCK', Image.ENCODERS)
|
||||
|
||||
enc = Image._getencoder('RGB', 'MOCK', ('args',), extra=('extra',))
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user