mirror of
https://github.com/python-pillow/Pillow.git
synced 2024-12-25 17:36:18 +03:00
Sort extensions alphabetically in error message
This commit is contained in:
parent
e14072e973
commit
dbe979d032
|
@ -469,7 +469,7 @@ def test_load_when_image_not_found(tmp_path: Path) -> None:
|
|||
ImageFont.load(tempfile)
|
||||
|
||||
root = os.path.splitext(tempfile)[0]
|
||||
assert str(e.value) == f"cannot find glyph data file {root}.{{png|gif|pbm}}"
|
||||
assert str(e.value) == f"cannot find glyph data file {root}.{{gif|pbm|png}}"
|
||||
|
||||
|
||||
def test_load_path_not_found() -> None:
|
||||
|
|
|
@ -115,7 +115,7 @@ class ImageFont:
|
|||
if image:
|
||||
image.close()
|
||||
|
||||
msg = f"cannot find glyph data file {root}.{{png|gif|pbm}}"
|
||||
msg = f"cannot find glyph data file {root}.{{gif|pbm|png}}"
|
||||
raise OSError(msg)
|
||||
|
||||
self.file = fullname
|
||||
|
|
Loading…
Reference in New Issue
Block a user