From 1edea552bf7bdc1c470686351aae715769bff050 Mon Sep 17 00:00:00 2001 From: AIOSAI Date: Thu, 9 Jul 2026 16:53:14 -0700 Subject: [PATCH] =?UTF-8?q?backup:=20fix=20Windows-incompat=20test=20?= =?UTF-8?q?=E2=80=94=20test=5Flog=5Foperation=5Fhandles=5Fpath=5Fobjects?= =?UTF-8?q?=20asserted=20a=20hardcoded=20POSIX=20'/some/project';=20defaul?= =?UTF-8?q?t=3Dstr=20serializes=20with=20platform=20separators,=20so=20com?= =?UTF-8?q?pare=20against=20str(Path(...)).=20Pre-existing=20(S284=20195b9?= =?UTF-8?q?f0),=20the=20sole=20repo-wide=20Windows=20CI=20red?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/aipass/backup/tests/test_json_handler.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/aipass/backup/tests/test_json_handler.py b/src/aipass/backup/tests/test_json_handler.py index 53bd42c0..d982363d 100644 --- a/src/aipass/backup/tests/test_json_handler.py +++ b/src/aipass/backup/tests/test_json_handler.py @@ -144,7 +144,9 @@ class TestLogOperation: log_file = log_dir / "operations.jsonl" if log_file.exists(): entry = json.loads(log_file.read_text(encoding="utf-8").strip()) - assert entry["project_root"] == "/some/project" + # default=str serializes via str(Path(...)) — platform-native separators, + # so compare against the same (POSIX "/some/project", Windows "\some\project"). + assert entry["project_root"] == str(Path("/some/project")) class TestEnsureAndGetPath: