mirror of
https://github.com/python-pillow/Pillow.git
synced 2025-08-25 06:34:48 +03:00
Added test
This commit is contained in:
parent
b18255e298
commit
3f9af46f88
|
@ -420,6 +420,10 @@ class TestImageFont(PillowTestCase):
|
||||||
self.assertRaises(IOError, ImageFont.load_path, filename)
|
self.assertRaises(IOError, ImageFont.load_path, filename)
|
||||||
self.assertRaises(IOError, ImageFont.truetype, filename)
|
self.assertRaises(IOError, ImageFont.truetype, filename)
|
||||||
|
|
||||||
|
def test_load_non_font_bytes(self):
|
||||||
|
with open("Tests/images/hopper.jpg", "rb") as f:
|
||||||
|
self.assertRaises(IOError, ImageFont.truetype, f)
|
||||||
|
|
||||||
def test_default_font(self):
|
def test_default_font(self):
|
||||||
# Arrange
|
# Arrange
|
||||||
txt = 'This is a "better than nothing" default font.'
|
txt = 'This is a "better than nothing" default font.'
|
||||||
|
|
Loading…
Reference in New Issue
Block a user