Skip to content

Commit

Permalink
Specify file encodings in test_renderer.py
Browse files Browse the repository at this point in the history
This should make the test suite pass in CI.
  • Loading branch information
yut23 committed Jan 16, 2025
1 parent 5f378ca commit 47fe4a8
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions tests/test_renderer.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ def app(test_params, app_params, make_app, shared_result):
args, kwargs = app_params
assert "srcdir" in kwargs
os.makedirs(kwargs["srcdir"], exist_ok=True)
(kwargs["srcdir"] / "conf.py").write_text("")
(kwargs["srcdir"] / "conf.py").write_text("", encoding="ascii")
app_ = make_app(*args, **kwargs)
yield app_

Expand Down Expand Up @@ -547,7 +547,7 @@ def get_matches(datafile):
from xml.dom import minidom

argsstrings = []
with open(os.path.join(os.path.dirname(__file__), "data", datafile)) as fid:
with open(os.path.join(os.path.dirname(__file__), "data", datafile), encoding="utf-8") as fid:
xml = fid.read()
doc = minidom.parseString(xml)

Expand Down

0 comments on commit 47fe4a8

Please sign in to comment.