feat(uikit): add room to some other interaction contexts#39719
feat(uikit): add room to some other interaction contexts#39719
Conversation
|
Looks like this PR is not ready to merge, because of the following issues:
Please fix the issues and try again If you have any trouble, please check the PR guidelines |
🦋 Changeset detectedLatest commit: 4c13525 The changes in this PR will be included in the next version bump. This PR includes changesets to release 42 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## develop #39719 +/- ##
===========================================
- Coverage 70.61% 70.60% -0.02%
===========================================
Files 3256 3256
Lines 115778 115777 -1
Branches 21042 21059 +17
===========================================
- Hits 81756 81743 -13
- Misses 31965 31976 +11
- Partials 2057 2058 +1
Flags with carried forward coverage won't be shown. Click here to find out more. 🚀 New features to boost your workflow:
|
3c70293 to
0e855fe
Compare
|
@copilot This solution doesn't work because the UiKitModal component is not rendered inside the component tree that provides the RoomContext; so it will always be undefined. We need to find a way for the ActionManager to access the rid from a context, and pass it over on line 260 |
You're right. I've fixed this by tracking
Commit: 23cdcc8 |
e575cf8 to
a371882
Compare
e4ec352 to
c25a09a
Compare
Fixed in fbf30d1. The CI failure was a Prettier lint error in |
Co-authored-by: d-gubert <[email protected]>
Co-authored-by: d-gubert <[email protected]>
Co-authored-by: d-gubert <[email protected]>
Co-authored-by: d-gubert <[email protected]> Agent-Logs-Url: https://github.com/RocketChat/Rocket.Chat/sessions/1d9fe17e-f376-436c-a62e-97a42942ac9e
Co-authored-by: d-gubert <[email protected]> Agent-Logs-Url: https://github.com/RocketChat/Rocket.Chat/sessions/1d9fe17e-f376-436c-a62e-97a42942ac9e
Co-authored-by: d-gubert <[email protected]> Agent-Logs-Url: https://github.com/RocketChat/Rocket.Chat/sessions/9124b5cb-6821-4135-a3ed-9ac62f9f0d24
fbf30d1 to
312e538
Compare
|
@copilot the test at apps/meteor/tests/end-to-end/apps/uikit-room-context.ts is not applicable - manually sending interactions defeats the purpose for the test. We'll actually need an e2e, playwright test. I've included a helper function for installing apps in apps/meteor/tests/e2e/fixtures/insert-apps.ts, and created the scaffold for the playwright test here apps/meteor/tests/e2e/apps/uikit-interactions.spec.ts You have to complete each test case with their appropriate validation. Include any extra test case if you deem necessary. You may need to add helpers to apps/meteor/tests/e2e while working on the tests, for instance to fetch apps' logs. Follow patterns in apps/meteor/tests/e2e for that. The app you've built does not provide all the functionality needed for all test cases. Review the app and add things accordingly. Refer back to my example app here for reference. |
- Enhanced test app to support modal, contextual bar, and message surfaces - Added getAppLogs helper to e2e fixtures for fetching app logs - Updated installLocalTestPackage to return app data - Completed all 7 Playwright test cases validating room, user, triggerId, actionId, and container - Removed old non-applicable end-to-end test (uikit-room-context.ts) - Updated README documentation for the enhanced test app Co-authored-by: d-gubert <[email protected]> Agent-Logs-Url: https://github.com/RocketChat/Rocket.Chat/sessions/ec71feb5-1416-4b80-8e2f-b03c571ccef4
Implemented in a9d6682 and b8fa0f8. Changes made:
Warning Firewall rules blocked me from connecting to one or more addresses (expand for details)I tried to connect to the following addresses, but was blocked by firewall rules:
If you need me to access, download, or install something from one of these locations, you can either:
|
|
@copilot https://github.com/RocketChat/Rocket.Chat/actions/runs/23468073147/job/68285933076?pr=39719 CI issue involving your changes This one is unrelated, don't worry about it |
Opening a contextual bar via the Apps Engine triggers a client-side
URL navigation (to /channel/{room}/app/{viewId}). Calling waitFor on
a locator while this navigation is still in progress causes Playwright
to throw "Target page, context or browser has been closed".
Add page.waitForURL(/\/app\//) after dispatching the contextual bar
slash command in all three contextual bar tests to ensure the
navigation completes before any locator operations.
Co-authored-by: d-gubert <[email protected]>
Agent-Logs-Url: https://github.com/RocketChat/Rocket.Chat/sessions/1998ca62-abf1-478a-835c-d3ea1053d273
Fixed in 56e9106. The failure was caused by a race condition: when The fix adds |
|
closing in favor of #39858 |
ridto server (ActionManager approach)modal,ctx(contextual bar), andmessageexecuteBlockActionHandler,executeViewSubmitHandler,executeViewClosedHandleruikit-interactions.spec.ts)getAppLogshelper and updateinstallLocalTestPackageto return app data ininsert-apps.tsexecuteBlockActionHandlerfrom message, contextual bar, and modal surfacesexecuteViewSubmitHandlerfrom modal and contextual bar surfacesexecuteViewClosedHandlerfrom modal and contextual bar surfacesuikit-room-test_0.0.1.zipinapp-packages/README.mdwith full TypeScript source💬 Send tasks to Copilot coding agent from Slack and Teams to turn conversations into code. Copilot posts an update in your thread when it's finished.