[MBL-19970][All] - Fix Help Menu E2E tests#3664
[MBL-19970][All] - Fix Help Menu E2E tests#3664kdeakinstructure wants to merge 2 commits intomasterfrom
Conversation
…s and Intent URLS) refs: MBL-19970 affects: Parent, Student, Teacher release note: -
🧪 Unit Test Results✅ 📱 Parent App
✅ 📱 Student App
✅ 📱 Teacher App
✅ 🌅 Horizon
✅ 📦 Submodules
📊 Summary
Last updated: Fri, 24 Apr 2026 13:47:16 GMT |
📊 Code Coverage Report✅ Student
✅ Teacher
✅ Pandautils
📈 Overall Average
|
There was a problem hiding this comment.
Pull request overview
Updates Help Menu E2E test selectors and expectations to match recent Help Menu copy/link changes across Parent, Student, and Teacher apps.
Changes:
- Replaced the “Submit a Feature Idea” Help Menu entry strings with “Share a Contribution” in shared test constants.
- Updated Help Page test page objects to locate/assert the renamed Help Menu item.
- Updated Help Menu E2E tests to expect the new “Share a Contribution” destination URL.
Reviewed changes
Copilot reviewed 7 out of 7 changed files in this pull request and generated 7 comments.
Show a summary per file
| File | Description |
|---|---|
| automation/espresso/src/main/kotlin/com/instructure/canvas/espresso/StringConstants.kt | Renames shared Help Menu string constants used by UI/E2E tests. |
| apps/teacher/src/androidTest/java/com/instructure/teacher/ui/pages/classic/HelpPage.kt | Updates Teacher Help dialog selectors/assertions to the new menu item title/subtitle. |
| apps/teacher/src/androidTest/java/com/instructure/teacher/ui/e2e/classic/HelpMenuE2ETest.kt | Updates expected intent URL for the renamed menu item. |
| apps/student/src/androidTest/java/com/instructure/student/ui/pages/classic/HelpPage.kt | Updates Student Help dialog selectors/assertions to the new menu item title/subtitle. |
| apps/student/src/androidTest/java/com/instructure/student/ui/e2e/classic/HelpMenuE2ETest.kt | Updates expected intent URL for the renamed menu item. |
| apps/parent/src/androidTest/java/com/instructure/parentapp/ui/pages/classic/HelpPage.kt | Updates Parent Help dialog selectors/assertions to the new menu item title/subtitle. |
| apps/parent/src/androidTest/java/com/instructure/parentapp/ui/e2e/classic/HelpMenuE2ETest.kt | Updates expected intent URL for the renamed menu item. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| @@ -57,7 +57,7 @@ class HelpPage : BasePage(R.id.helpDialog) { | |||
| /** | |||
| * The label for submitting a feature idea. | |||
There was a problem hiding this comment.
The KDoc above this label is now inaccurate (it still mentions submitting a feature idea). Update it to reflect the new 'Share a Contribution' menu item to avoid misleading future test maintenance.
| * The label for submitting a feature idea. | |
| * The label for sharing a contribution. |
| * The label for submitting a feature idea. | ||
| */ | ||
| private val submitFeatureLabel by OnViewWithStringTextIgnoreCase("Submit a Feature Idea") | ||
| private val shareContributionLabel by OnViewWithStringTextIgnoreCase("Share a Contribution") |
There was a problem hiding this comment.
This view matcher hard-codes the label text. Since the canonical title exists as HelpMenu.SHARE_A_CONTRIBUTION_TITLE, consider referencing that constant here to avoid future breakages if the UI string changes again.
| private val shareContributionLabel by OnViewWithStringTextIgnoreCase("Share a Contribution") | |
| private val shareContributionLabel by OnViewWithStringTextIgnoreCase(HelpMenu.SHARE_A_CONTRIBUTION_TITLE) |
| * Clicks on the 'Submit a Feature Idea' help menu. | ||
| */ | ||
| private fun clickSubmitFeatureLabel() { |
There was a problem hiding this comment.
The method name and KDoc still refer to 'Submit a Feature Idea', but it now clicks the 'Share a Contribution' item. Consider renaming the function (and updating call sites in the when-branch) so the code reflects current behavior and is easier to follow.
| * Clicks on the 'Submit a Feature Idea' help menu. | |
| */ | |
| private fun clickSubmitFeatureLabel() { | |
| * Clicks on the 'Share a Contribution' help menu. | |
| */ | |
| private fun clickShareContributionLabel() { |
| private val searchGuidesLabel by OnViewWithText(R.string.searchGuides) | ||
| private val reportProblemLabel by OnViewWithStringTextIgnoreCase("Report a Problem") | ||
| private val submitFeatureLabel by OnViewWithStringTextIgnoreCase("Submit a Feature Idea") | ||
| private val shareContributionLabel by OnViewWithStringTextIgnoreCase("Share a Contribution") |
There was a problem hiding this comment.
This view matcher hard-codes the menu label text. Since HelpMenu.SHARE_A_CONTRIBUTION_TITLE is the canonical value used elsewhere in this class, use that constant here to prevent string drift across tests.
| private val shareContributionLabel by OnViewWithStringTextIgnoreCase("Share a Contribution") | |
| private val shareContributionLabel by OnViewWithStringTextIgnoreCase(HelpMenu.SHARE_A_CONTRIBUTION_TITLE) |
| fun clickSubmitFeatureLabel() { | ||
| submitFeatureLabel.scrollTo().click() | ||
| shareContributionLabel.scrollTo().click() | ||
| } |
There was a problem hiding this comment.
This function name no longer matches its behavior (it clicks 'Share a Contribution'). Consider renaming it (and updating the when-branch that calls it) to keep the page object API self-explanatory.
| private val reportProblemLabel by OnViewWithStringTextIgnoreCase("Report a Problem") | ||
|
|
||
| private val submitFeatureLabel by OnViewWithStringTextIgnoreCase("Submit a Feature Idea") | ||
| private val shareContributionLabel by OnViewWithStringTextIgnoreCase("Share a Contribution") |
There was a problem hiding this comment.
This view matcher hard-codes the menu label text. Prefer using HelpMenu.SHARE_A_CONTRIBUTION_TITLE here to keep the selector consistent with the rest of the assertions and avoid future string changes breaking the test.
| private val shareContributionLabel by OnViewWithStringTextIgnoreCase("Share a Contribution") | |
| private val shareContributionLabel by OnViewWithStringTextIgnoreCase(HelpMenu.SHARE_A_CONTRIBUTION_TITLE) |
| private fun clickSubmitFeatureLabel() { | ||
| submitFeatureLabel.scrollTo().click() | ||
| shareContributionLabel.scrollTo().click() | ||
| } |
There was a problem hiding this comment.
The helper method name still refers to submitting a feature, but it now clicks 'Share a Contribution'. Consider renaming the method and updating the when-branch call so the intent assertion logic reads clearly.
Fix breaking Help Menu E2E tests in all the apps (Changed some strings and Intent URLS)
refs: MBL-19970
affects: Parent, Student, Teacher
release note: -