diff options
author | 2023-05-13 14:28:44 +0100 | |
---|---|---|
committer | 2023-05-13 14:34:32 +0100 | |
commit | bc4fb26606e1e7821525dbb617f35f96cf3b6be3 (patch) | |
tree | d4973072b2ab4b93c1d5d04e781b9bc599e5874b | |
parent | Upgrade to Python 3.11 (diff) |
Specify file encoding so tests pass on windows
This file has non-cp1252 characters, which is the default on windows, so fails to read the file.
-rw-r--r-- | pydis_site/apps/api/tests/test_rules.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/pydis_site/apps/api/tests/test_rules.py b/pydis_site/apps/api/tests/test_rules.py index 662fb8e9..14412b90 100644 --- a/pydis_site/apps/api/tests/test_rules.py +++ b/pydis_site/apps/api/tests/test_rules.py @@ -56,7 +56,7 @@ class RuleCorrectnessTests(AuthenticatedAPITestCase): ) markdown_rules = [] - for line in markdown_rules_path.read_text().splitlines(): + for line in markdown_rules_path.read_text(encoding="utf8").splitlines(): matches = self.markdown_rule_re.match(line) if matches is not None: markdown_rules.append(matches.group(1)) |