test: read static assets as utf-8 so locale/render tests run on Windows
34 test files read static/*.js via read_text()/open() without an encoding, so Python's cp1252 default on Windows choked on non-Latin1 bytes and errored at collection (Ubuntu CI defaults to utf-8, so it never saw this). Add explicit encoding="utf-8" to those reads — purely mechanical, no assertion changes. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
1 parent
980e98dc7e
commit
5f0cc6c567
34 files changed
+145
-145
No files matched your search
@@ -3,12 +3,12 @@ import re
|
||||
|
||||
|
||||
def _src(name: str) -> str:
|
||||
with open(f"static/{name}") as f:
|
||||
with open(f"static/{name}", encoding="utf-8") as f:
|
||||
return f.read()
|
||||
|
||||
|
||||
def _py_src() -> str:
|
||||
with open("api/helpers.py") as f:
|
||||
with open("api/helpers.py", encoding="utf-8") as f:
|
||||
return f.read()
|
||||
|
||||
|
||||
|
||||
Reference in new issue
Block a user