From bc71685d229baa28fdee8bb1928b82e9f632e0a4 Mon Sep 17 00:00:00 2001 From: =?utf8?q?=C5=81ukasz=20Langa?= Date: Thu, 20 Aug 2020 19:21:40 +0200 Subject: [PATCH] Open file explicitly with UTF-8 so it works on Windows, too --- tests/test_black.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/test_black.py b/tests/test_black.py index 7793b0e..f89f140 100644 --- a/tests/test_black.py +++ b/tests/test_black.py @@ -2062,7 +2062,7 @@ class BlackDTestCase(AioHTTPTestCase): self.assertIsNotNone(response.headers.get(blackd.BLACK_VERSION_HEADER)) -with open(black.__file__, "r") as _bf: +with open(black.__file__, "r", encoding="utf-8") as _bf: black_source_lines = _bf.readlines() -- 2.39.5