Test passing Path to truetype

This commit is contained in:
Andrew Murray 2021-08-01 14:22:00 +10:00 committed by Alexander Schlarb
parent ebf82e41c9
commit 44c7fc9a23

View File

@ -1,4 +1,5 @@
import copy import copy
from pathlib import Path
import os import os
import re import re
import shutil import shutil
@ -87,6 +88,7 @@ class TestImageFont:
pytest.skip("Non-ASCII path could not be created") pytest.skip("Non-ASCII path could not be created")
ImageFont.truetype(tempfile, FONT_SIZE) ImageFont.truetype(tempfile, FONT_SIZE)
ImageFont.truetype(Path(tempfile), FONT_SIZE)
def test_unavailable_layout_engine(self): def test_unavailable_layout_engine(self):
have_raqm = ImageFont.core.HAVE_RAQM have_raqm = ImageFont.core.HAVE_RAQM