From 22ce5cc0c7cf9129cd74be8a6b22fb8be8a79f1d Mon Sep 17 00:00:00 2001 From: nulano Date: Tue, 2 Jul 2019 11:08:48 +0200 Subject: [PATCH 1/2] Revert "Update epsilon for FreeType 2.10 with eg. Unicode width 16" --- Tests/test_imagefont.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/Tests/test_imagefont.py b/Tests/test_imagefont.py index 34ddbd53b..5532750fe 100644 --- a/Tests/test_imagefont.py +++ b/Tests/test_imagefont.py @@ -53,8 +53,7 @@ class TestImageFont(PillowTestCase): # (and, other things, but first things first) METRICS = { (">=2.3", "<2.4"): {"multiline": 30, "textsize": 12, "getters": (13, 16)}, - (">=2.7", "<2.10"): {"multiline": 6.2, "textsize": 2.5, "getters": (12, 16)}, - (">=2.10",): {"multiline": 14.8, "textsize": 2.5, "getters": (12, 16)}, + (">=2.7",): {"multiline": 6.2, "textsize": 2.5, "getters": (12, 16)}, "Default": {"multiline": 0.5, "textsize": 0.5, "getters": (12, 16)}, } From d7c69ea2b461f1c4305888934013edd5278f8ffb Mon Sep 17 00:00:00 2001 From: nulano Date: Tue, 2 Jul 2019 11:14:09 +0200 Subject: [PATCH 2/2] skip test_unicode_extended on Python 2.x --- Tests/test_imagefont.py | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/Tests/test_imagefont.py b/Tests/test_imagefont.py index 5532750fe..ee630a556 100644 --- a/Tests/test_imagefont.py +++ b/Tests/test_imagefont.py @@ -463,10 +463,7 @@ class TestImageFont(PillowTestCase): with self.assertRaises(UnicodeEncodeError): font.getsize(u"’") - @unittest.skipIf( - sys.platform.startswith("win32") and sys.version.startswith("2"), - "requires Python 3.x on Windows", - ) + @unittest.skipIf(sys.version.startswith("2"), "requires Python 3.3+") def test_unicode_extended(self): # issue #3777 text = u"A\u278A\U0001F12B"