mirror of
https://github.com/razzant/ouroboros.git
synced 2026-10-03 04:07:04 +00:00
Read the accounting test fixtures as UTF-8
The Windows full-test leg runs Python without UTF-8 mode, so a bare Path.read_text() decodes with the locale codepage. The payloads here are ASCII today; the explicit encoding keeps the test honest when they are not.
This commit is contained in:
parent
7298277d95
commit
aaa3d70424
1 changed files with 2 additions and 2 deletions
|
|
@ -122,7 +122,7 @@ def wire_env(tmp_path, monkeypatch):
|
|||
|
||||
def _store(evidence):
|
||||
path = evidence / "state" / wire.REQUEST_WIRE_STATE_FILE
|
||||
return json.loads(path.read_text()) if path.exists() else None
|
||||
return json.loads(path.read_text(encoding="utf-8")) if path.exists() else None
|
||||
|
||||
|
||||
def _learned_actions(evidence):
|
||||
|
|
@ -136,7 +136,7 @@ def _learned_actions(evidence):
|
|||
|
||||
def _rows(root):
|
||||
path = root / ua.LEDGER_REL
|
||||
return [json.loads(line) for line in path.read_text().splitlines() if line.strip()]
|
||||
return [json.loads(line) for line in path.read_text(encoding="utf-8").splitlines() if line.strip()]
|
||||
|
||||
|
||||
def _capture(candidate, *, state="settled", attempt="attempt-wire", digest=None,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue