Repository navigation
test(playwright): dismiss AI alert popovers from the start of the subtitle - #38605
Conversation
…title #38286 added the Enabled row to the alert form, so on the profile alert page the source picker opens its list upwards over the middle of the header subtitle and dismissPopover's click lands on an option row. Click the subtitle's start, as closeSourcePicker already does.
closeSourcePicker repeated dismissPopover's subtitle click, and the two drifted apart once already. Reuse it.
Code Review ✅ Approved 🟢 Low riskThe change adjusts a Playwright helper’s click point and reuses it for the profile picker; it affects test interactions, not application behavior. Changes the VerificationRules No rules evaluated Functional validation Not enabledAuto-approval Not enabledFor more verification details, comment OptionsDisplay: compact → Showing compact verification results. Comment with these commands to change the behavior for this request:
Was this helpful? React with 👍 / 👎 | Powered by Gitar — free for open source |
UI browser testsRan: all test files (no impact map from main yet) Result: ✅ 1070 passed · 154 skipped |
…title (#38605) (#38653) * test(playwright): dismiss AI alert popovers from the start of the subtitle #38286 added the Enabled row to the alert form, so on the profile alert page the source picker opens its list upwards over the middle of the header subtitle and dismissPopover's click lands on an option row. Click the subtitle's start, as closeSourcePicker already does. * test(playwright): close the profile source picker through dismissPopover closeSourcePicker repeated dismissPopover's subtitle click, and the two drifted apart once already. Reuse it. (cherry picked from commit 2d215b7)
Describe your changes:
Fixes the
AlertNotificationTemplateAiModefailure: Collate's merge queue has failed on it since #38286. Companion Collate PR: https://github.com/open-metadata/openmetadata-collate/pull/8914, which this unblocks; it needs no Collate change, because Collate imports this helper from the OSS mirror. Test fix, so no issue (labelledskip-pr-checks).dismissPopoverinplaywright/e2e/Utils/aiAlertDrawer.tsnow clicks the start of the header subtitle (position: { x: 4, y: 4 }) instead of its centre. #38286 had already made that change in its siblingcloseSourcePicker(utils/profileNotificationAlert.ts), but not here.closeSourcePickernow callsdismissPopoverinstead of repeating it, so the two can't drift apart again.RCA. From the Collate merge-queue run https://github.com/open-metadata/openmetadata-collate/actions/runs/45375767906/job/138395224645:
AlertNotificationTemplateAiModetests timed out on the profile alert page (ai-profile-page).selectAlertSource→dismissPopoveron the subtitle "Stay current with timely alerts using webhooks." retried for the whole test budget.tw:flex tw:w-full tw:min-w-0 tw:flex-1 tw:flex-wrap tw:gap-x-2div intercepts pointer events.40e75c179d4) added the Enabled settings row to the top of the alert form.Suggestionslistbox opens upwards over the middle of the subtitle.closeSourcePicker, which OSS's profile-page specs use, to the subtitle's start.dismissPopoverunchanged. That one is shared by the drawer specs and by Collate's profile-page spec.Type of change:
High-level design:
N/A — one test helper, one line.
Tests:
Use cases covered
AlertNotificationTemplateAiMode): the source picker opens upwards over the subtitle. The dismiss now lands on uncovered text.AiObservabilityAlerts,AiAlertSeveralSources): the dismiss keeps closing the popover.ProfileNotificationTab,AiAlertSeveralSources› profile):closeSourcePickernow goes throughdismissPopover.Unit tests
Not applicable — Playwright helper only.
Backend integration tests
Not applicable — no backend changes.
Ingestion integration tests
Not applicable — no ingestion changes.
Playwright (UI) tests
Collate UI served by vite from this branch, which includes #38286, against a Collate
:8585backend. All runs use--retries=0.AlertNotificationTemplateAiMode.spec.ts, control (helper frommain)AlertNotificationTemplateAiMode.spec.ts, this branch--repeat-each=3Features/AIMode/AiObservabilityAlerts.spec.tsandFeatures/AIMode/AiAlertSeveralSources.spec.ts(every otherdismissPopovercaller), on22a71590adeaa59f7b0c3f: CollateAlertNotificationTemplateAiMode.spec.ts,--repeat-each=10 --workers=4aa59f7b0c3f:ProfileNotificationTab,AiAlertSeveralSourcesandAiObservabilityAlerts,--repeat-each=10 --workers=4The 10 failures are all one test, and they come from my local setup.
ProfileNotificationTab› Alert with recent events check throwsPLAYWRIGHT_WEBHOOK_HOST must be defined… cannot reach the Playwright webhook receiver through localhostbefore it reaches the UI. It fails the same way withmain's helpers (control run, 2/2 failed).yarn lint:playwright: 0 errors. The 193 warnings are all in untouched files.Result (HTML report screenshot)
Manual testing performed
Suggestionslistbox is open over the profile page's header, under the new Enabled row.main's helper (the control above), then confirmed the fix on the same UI.UI screen recording:
Not applicable — this changes a test helper only; no UI behaviour changes.
Checklist:
Fixes <issue-number>: <short explanation>— test fix, so it has a descriptive title instead.Fixes #<issue-number>above — test fix, labelledskip-pr-checks.REVIEW.md(thepr-checklistskill runs it) and fixed every 🔴 finding, or answered it on the line below.Reviewed with fresh context against
REVIEW.mdand the handbook.22a71590ade: no 🔴. Fixed 🟡 "copies an existing helper" inaa59f7b0c3f:closeSourcePickernow reusesdismissPopover, and the comment names the Collate caller. Answered 🟡 "green check cannot cover the profile-page case" with the Collate control and stability runs above.aa59f7b0c3f: no 🔴. Its 🟡 asks the description to saydismissPopover's click point changes for every caller; it does.🤖 Generated with Claude Code