feat(debug): migrate one conversation to MLS - WPB-23052#5049
feat(debug): migrate one conversation to MLS - WPB-23052#5049MohamadJaara wants to merge 4 commits into
Conversation
There was a problem hiding this comment.
Pull request overview
Adds a developer-mode-only action in the conversation details UI to migrate a single eligible team group conversation from Proteus/mixed to MLS, backed by a focused data-model use case and tests. This supports targeted MLS migration testing without triggering the broader rollout coordinator.
Changes:
- Add a new conversation action (“Migrate to MLS”) gated behind developer mode + eligibility checks, with confirmation and success/failure feedback.
- Introduce
MigrateConversationToMLSUseCaseto handle Proteus → mixed → MLS and mixed → MLS, including MLS group establish/join steps. - Add UI locator + data-model unit tests covering Proteus/mixed/MLS/missing/unsupported scenarios.
Reviewed changes
Copilot reviewed 6 out of 6 changed files in this pull request and generated 4 comments.
Show a summary per file
| File | Description |
|---|---|
| WireUI/Sources/WireLocators/Locators.swift | Adds a new locator for the MLS migration action. |
| wire-ios/Wire-iOS/Sources/UserInterface/GroupDetails/ConversationActions/ConversationActionController+MLSMigration.swift | Implements the UI confirmation flow and triggers the migration use case. |
| wire-ios/Wire-iOS/Sources/UserInterface/GroupDetails/ConversationActions/ConversationActionController.swift | Wires the new action into the controller action dispatcher. |
| wire-ios/Wire-iOS/Sources/UserInterface/GroupDetails/ConversationActions/ConversationAction.swift | Adds the new action, gating logic, title, and accessibility identifier mapping. |
| wire-ios-data-model/Tests/MLS/MigrateConversationToMLSUseCaseTests.swift | Adds unit tests for the focused migration use case. |
| wire-ios-data-model/Source/MLS/Migration/MigrateConversationToMLSUseCase.swift | Adds the focused migration use case implementation. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| case .migrateToMLS: | ||
| return "Migrate to MLS" |
| let controller = UIAlertController( | ||
| title: "Migrate conversation to MLS?", | ||
| message: "This internal action bypasses the normal MLS rollout conditions and immediately migrates this conversation.", | ||
| preferredStyle: .alert | ||
| ) | ||
| controller.addAction(.cancel()) | ||
| controller.addAction( | ||
| UIAlertAction( | ||
| title: "Migrate", | ||
| style: .destructive, | ||
| accessibilityIdentifier: Locators.ConversationDetailsActions.migrateToMLS.rawValue |
Test Results4 500 tests 4 472 ✅ 6m 55s ⏱️ Results for commit ebbc5bc. ♻️ This comment has been updated with latest results. Summary: workflow run #30121676248 |
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
What changed
Why
Developers need a targeted way to exercise MLS migration for one conversation without triggering the normal bulk rollout flow.
Impact
The option is only visible when developer mode is enabled, and only for non-MLS group conversations in the self user's team. Production users do not see the action.
Validation
The focused migration use-case tests pass, and the full Wire-iOS app target builds successfully from a clean derived-data directory.