From e74cc7f898f62befa28987a86f287b6e69b6fd66 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=EC=9C=A0=EC=B0=BD=EC=9A=B1?= Date: Sat, 11 Jul 2026 21:43:35 +0900 Subject: [PATCH] test(edge): cover ghost/zone env overrides and config defaults --- tests/test_config.py | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/tests/test_config.py b/tests/test_config.py index 5960f61..9b0f5a6 100644 --- a/tests/test_config.py +++ b/tests/test_config.py @@ -5,6 +5,12 @@ def test_defaults_when_env_empty(): assert cfg.device_id == "pi-unknown" assert cfg.fall.prone_confirm_s == 3.0 assert cfg.fall.no_motion_s == 10.0 + assert cfg.camera_id == "cam-01" + assert cfg.cafe24_url == "" + assert cfg.secret == "" + assert cfg.ghost.reappear_s == 10.0 + assert cfg.zone.debounce_s == 0.75 + assert cfg.engine.cooldown_s == 30.0 def test_env_overrides(): env = { @@ -12,6 +18,7 @@ def test_env_overrides(): "CAFE24_URL": "https://x/api/events", "DEVICE_SECRET": "s", "FALL_PRONE_S": "2.0", "FALL_NO_MOTION_S": "8", "IMMOBILE_S": "90", "COOLDOWN_S": "45", + "GHOST_REAPPEAR_S": "7", "ZONE_DEBOUNCE_S": "1.5", } cfg = load_config(env) assert cfg.device_id == "pi-w1" @@ -21,3 +28,5 @@ def test_env_overrides(): assert cfg.immobility.immobile_s == 90.0 assert cfg.engine.cooldown_s == 45.0 assert cfg.engine.camera_id == "cam-9" + assert cfg.ghost.reappear_s == 7.0 + assert cfg.zone.debounce_s == 1.5