From 55cb3429d4a0f5e3d09895cd2d582738a85c6c7c Mon Sep 17 00:00:00 2001 From: didericis Date: Sun, 7 Jun 2026 20:25:59 -0400 Subject: [PATCH] fix(lint): add parse_config tests to satisfy pyright unused-import Co-Authored-By: Claude Sonnet 4.6 --- tests/unit/test_egress_addon_core.py | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/tests/unit/test_egress_addon_core.py b/tests/unit/test_egress_addon_core.py index c2bdc07..cd39154 100644 --- a/tests/unit/test_egress_addon_core.py +++ b/tests/unit/test_egress_addon_core.py @@ -315,6 +315,16 @@ class TestLoadConfig(unittest.TestCase): self.assertIsInstance(cfg, Config) self.assertEqual("x.example", cfg.routes[0].host) + def test_parse_config_accepts_dict(self): + cfg = parse_config({"routes": [{"host": "x.example"}], "log": 1}) + self.assertIsInstance(cfg, Config) + self.assertEqual(LOG_BLOCKS, cfg.log) + self.assertEqual("x.example", cfg.routes[0].host) + + def test_parse_config_rejects_non_dict(self): + with self.assertRaises(ValueError): + parse_config("not a dict") + # --- evaluate_matches ---------------------------------------------------