Peach: Local-first video metadata scraper and media manager.
fix: stop two Windows-shaped assertions from failing the macOS suite
Peach local maintenance140049632401
diff --git a/tests/test_rm_web.py b/tests/test_rm_web.pyindex 886ee6e4a..b5070352c 100644--- a/tests/test_rm_web.py+++ b/tests/test_rm_web.py@@ -198,7 +198,13 @@ class WebDataTests(unittest.TestCase):"shutil.disk_usage", return_value=usage,):stats = rm_web.q_stats(self.contract)- self.assertEqual(stats["system_disk"], {"root": "X:\\", "free": 20, "total": 100})+ # 断言的是「用了 platform 给的系统卷」,不是盘符的字符串写法:+ # `Path("X:/")` 在 Windows 上渲染成 `X:\`、在 POSIX 上渲染成 `X:/`,+ # 写死反斜杠会让这条只在 Windows 通过。+ self.assertEqual(+ stats["system_disk"],+ {"root": str(Path("X:/")), "free": 20, "total": 100},+ )self.assertIs(stats["disk_c"], stats["system_disk"])def test_items_support_duration_range(self):diff --git a/tests/test_tray.py b/tests/test_tray.pyindex eaa831744..1c1746e88 100644--- a/tests/test_tray.py+++ b/tests/test_tray.py@@ -61,6 +61,9 @@ class TrayTests(unittest.TestCase):for spec in specs:self.assertIn("--no-ledger-sync", spec.command)+ @unittest.skipUnless(+ os.name == "nt", "macOS 走 build_macos_service_specs,不发布 LAN 地址"+ )def test_windows_service_address_uses_the_current_route_when_not_configured(self):with tempfile.TemporaryDirectory() as directory:tls_dir = Path(directory)