Added unit tests for event registration, dispatching, and context infrastructure.
CI / Formatting (push) Successful in 12s
CI / Linting (push) Successful in 13s
CI / Tests (push) Successful in 22s
CI / Type Checking (push) Successful in 25s

- EventRegistry.get_all() now deep-copies handler lists so callers cannot mutate internal state.
This commit is contained in:
2026-02-18 19:16:26 -05:00
parent a7a7a24773
commit 334730f3aa
2 changed files with 1121 additions and 1 deletions
+3 -1
View File
@@ -138,7 +138,9 @@ class EventRegistry:
:return: Dict mapping event type values to handler lists.
"""
return self._handlers.copy()
return {
event_type: entries.copy() for event_type, entries in self._handlers.items()
}
def get_handler_module(self, handler: EventHandler) -> str | None:
"""
+1118
View File
File diff suppressed because it is too large Load Diff