Conversation
Co-authored-by: RubenGeo <34537157+RubenGeo@users.noreply.github.com>
Co-authored-by: RubenGeo <34537157+RubenGeo@users.noreply.github.com>
Co-authored-by: RubenGeo <34537157+RubenGeo@users.noreply.github.com>
Copilot created this pull request from a session on behalf of
RubenGeo
September 16, 2026 17:53
View session
RubenGeo
marked this pull request as ready for review
September 17, 2026 11:03
Contributor
There was a problem hiding this comment.
🔵 Needs a closer look
Scope the action-menu locator to the payment menu before approval.
Pull request overview
Improves portal payment E2E stability by retrying action-menu interactions and removing a flaky approval-badge assertion.
Changes:
- Adds retryable payment action-menu opening.
- Reuses the helper for delete and rename flows.
- Removes the flaky approval-badge check.
- The payment menu locator needs scoping to the correct menu.
File summaries
| File | Description |
|---|---|
e2e/portal/tests/ViewPayment/DeletePayment.spec.ts |
Removes the flaky badge check. |
e2e/portal/pages/PaymentPage.ts |
Adds resilient action-menu handling. |
Review details
Suppressed comments (1)
e2e/portal/pages/PaymentPage.ts:125
last()is not tied to the payment actions menu. The transaction-list page also renders QueryTable'sextraOptionsMenuafter the payment layout, so this locator can resolve to that table menu; the retry may then return because an unrelated menu is visible or wait for a menu that the ellipsis button never opened. Scope this locator to a menu containing the payment action items (or otherwise anchor it to the ellipsis component) before using it for delete/rename checks.
const actionsMenu = this.page.getByRole('menu').last();
- Files reviewed: 2/2 changed files
- Comments generated: 0
- Review effort level: Lite
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Contributor
There was a problem hiding this comment.
🔵 Needs a closer look
Scope the menu locator to payment action items to avoid selecting the export menu.
Review details
Suppressed comments (1)
e2e/portal/pages/PaymentPage.ts:125
- This page also renders the export
p-menu, so this page-wide locator can resolve to an already-open export menu. In that caseisVisible()returns true and the helper skips clicking the ellipsis button, after which the Delete/Rename lookup fails. Scope the locator to a menu containing the payment action items rather than selecting the last generic menu.
const actionsMenu = this.page.getByRole('menu').last();
- Files reviewed: 2/2 changed files
- Comments generated: 0 new
- Review effort level: Lite
RubenGeo
enabled auto-merge
September 17, 2026 15:58
Contributor
There was a problem hiding this comment.
🟡 Changes recommended
Scope the action-menu locator to support roles without the rename permission.
Get a fresh assessment by requesting another Copilot review.
Review details
- Files reviewed: 2/2 changed files
- Comments generated: 1
- Review effort level: Lite
Comment on lines
+125
to
+127
| const actionsMenu = this.page.getByRole('menu').filter({ | ||
| has: this.page.getByRole('menuitem', { name: 'Rename payment' }), | ||
| }); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
AB#44671
Describe your changes
PaymentPageaction menu operations (deletePayment,renamePayment,isDeletePaymentButtonVisible) by introducing an idempotentopenActionsMenu()helper that retries until the menu is open.isDeletePaymentButtonVisible()inexpect(...).toPass({ timeout: 15_000 })to eliminate race conditions between menu toggle animations and DOM visibility assertions.validateBadgeIsPresentByLabel({ badgeName: 'Approved', count: 1 })assertion inDeletePayment.spec.tswhich was susceptible to transient timing issues, relying on the toast confirmation and 'start' button visibility instead.Checklist before requesting a code review
Portal preview-deployment
This PR does not have any preview deployments yet.