refactor: rename initModularizedControllers to initMessengerClients and update result properties#28645
Conversation
|
CLA Signature Action: All authors have signed the CLA. You may need to manually re-run the blocking PR check if it doesn't pass in a few minutes. |
d94c76a to
56cc68e
Compare
13768ee to
6f60b10
Compare
…nd update result properties
6f60b10 to
8522bad
Compare
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #28645 +/- ##
==========================================
+ Coverage 82.14% 82.17% +0.02%
==========================================
Files 4949 4967 +18
Lines 130070 130768 +698
Branches 29004 29168 +164
==========================================
+ Hits 106851 107462 +611
- Misses 15923 15977 +54
- Partials 7296 7329 +33 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
…messenger-clients
🔍 Smart E2E Test Selection
click to see 🤖 AI reasoning detailsE2E Test Selection:
Why broad coverage: Although this is a rename/refactor, the Engine initialization is the foundation of the entire app. Any subtle bug introduced during this refactoring (e.g., the removal of Why not high risk: The changes are purely cosmetic renames with no algorithmic changes to the initialization logic itself. The unit tests have been updated to match. The removal of Performance Test Selection: |
|
|
✅ E2E Fixture Validation — Schema is up to date |



Description
Rename
initModularizedControllerstoinitMessengerClients, dropexistingControllersByName, renamecontrollerInitFunctionstoinitFunctions, and update return type tomessengerClientsByName. Update all consumers inEngine.ts,utils.test.ts, and test utility functions.80 files changed. PR 3 of 4 — depends on PR 2 (#28641).
PR 1: Core type renames (Controller→MessengerClient, etc.) (refactor: rename Controller types to MessengerClient types #28610)PR 2:CONTROLLER_MESSENGERS→MESSENGER_FACTORIES(refactor: rename CONTROLLER_MESSENGERS to MESSENGER_FACTORIES #28641)initModularizedControllers→initMessengerClients+ utils/Engine.ts renamescontroller→messengerClient,getController→getMessengerClient) in all init files + testsRelates to WPC-916.
Changelog
CHANGELOG entry: null
Related issues
Fixes: https://consensyssoftware.atlassian.net/browse/WPC-916
Manual testing steps
Screenshots/Recordings
N/A — no UI changes.
Before
N/A
After
N/A
Pre-merge author checklist
Pre-merge reviewer checklist
Note
Medium Risk
Refactors the Engine’s initialization wiring for all controller/messenger clients, so mistakes could break startup order or dependency resolution despite being a rename-focused change.
Overview
Renames and reshapes the Engine init helper by replacing
initModularizedControllerswithinitMessengerClients, renamingcontrollerInitFunctionstoinitFunctions, and returningmessengerClientsByName.Simplifies initialization state by dropping support for
existingControllersByNameand updating the dependency lookup helper/error messaging togetMessengerClientOrThrow.Updates
Engine.tswiring and a large set of controller init tests to use the new request mock helper (buildMessengerClientInitRequestMock) and the new result property names.Reviewed by Cursor Bugbot for commit 80bf6e1. Bugbot is set up for automated code reviews on this repo. Configure here.