-
Notifications
You must be signed in to change notification settings - Fork 0
FOLLOW-UP: Add integration tests for DOM event delegation paths (from PR #49) #50
Description
Context
This follow-up task was identified during the review of PR #49.
Source PR: #49
PR Title: feat: extend lvt-el: and lvt-fx: to support native DOM event triggers
Suggested by: @claude[bot], @copilot
Task Description
Add integration tests for the DOM event delegation system introduced in PR #49. Current tests cover processElementInteraction and setupFxDOMEventTriggers but miss several key paths:
- Wrapper-level bubbling delegation: Dispatch a real DOM event on a child element and assert the closest matching
lvt-el:*:on:{event}handler fires (and parent handlers don't) - Non-bubbling direct attachment: Test mouseenter/mouseleave/focus/blur listeners are attached directly to elements
- Lifecycle listener routing: Test
setupFxLifecycleListeners/processFxLifecycleAttributesfire effects onlvt:successetc. - Teardown/reconnect cycles: Test that
teardownDOMEventTriggerDelegationandteardownFxDOMEventTriggersproperly remove listeners and clear guard keys, allowing re-attachment on reconnect
Original Comments
"No automated tests cover setupDOMEventTriggerDelegation (bubbling vs non-bubbling events, delegation boundary)" — @copilot
"Tests were added for setupFxDOMEventTriggers but there's no test coverage for processElementInteraction or setupDOMEventTriggerDelegation firing actual DOM events" — @claude[bot]
This issue was automatically created by prmonitor from PR review comments.