From 09aabd3bd448bad5b82769d5da5249c1e441b54a Mon Sep 17 00:00:00 2001 From: Taneli Hukkinen <3275109+hukkin@users.noreply.github.com> Date: Sun, 1 Dec 2024 20:41:30 +0200 Subject: [PATCH] Read UTF-8 in tests --- tests/test_parse.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/test_parse.py b/tests/test_parse.py index be835e7..25fd835 100644 --- a/tests/test_parse.py +++ b/tests/test_parse.py @@ -25,7 +25,7 @@ def test_fixtures__cli(line, title, text, expected, tmp_path): file_path = tmp_path / "test_markdown.md" file_path.write_text(text, encoding="utf-8") assert mdformat._cli.run([str(file_path)]) == 0 - md_new = file_path.read_text() + md_new = file_path.read_text(encoding="utf-8") assert md_new == expected @@ -51,5 +51,5 @@ def test_fixtures_compact__cli(line, title, text, expected, tmp_path): file_path = tmp_path / "test_markdown.md" file_path.write_text(text, encoding="utf-8") assert mdformat._cli.run([str(file_path), "--compact-tables"]) == 0 - md_new = file_path.read_text() + md_new = file_path.read_text(encoding="utf-8") assert md_new == expected