This is an automated email from the ASF dual-hosted git repository.

vatsrahul1001 pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/airflow.git


The following commit(s) were added to refs/heads/main by this push:
     new 66ecac66d1f fix: connection dialog state handling in BasePage to avoid 
flaky tests (#67026)
66ecac66d1f is described below

commit 66ecac66d1ffdfc673276c0b30c57619e73caab4
Author: Yeonguk Choo <[email protected]>
AuthorDate: Sat May 16 17:11:39 2026 +0900

    fix: connection dialog state handling in BasePage to avoid flaky tests 
(#67026)
---
 airflow-core/src/airflow/ui/tests/e2e/pages/BasePage.ts | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/airflow-core/src/airflow/ui/tests/e2e/pages/BasePage.ts 
b/airflow-core/src/airflow/ui/tests/e2e/pages/BasePage.ts
index ae6e7ebe788..4eedd090928 100644
--- a/airflow-core/src/airflow/ui/tests/e2e/pages/BasePage.ts
+++ b/airflow-core/src/airflow/ui/tests/e2e/pages/BasePage.ts
@@ -56,13 +56,13 @@ export class BasePage {
     await this.page.goto(path, { waitUntil: "domcontentloaded" });
   }
 
-  // Chakra v3 / Ark UI keeps the backdrop in the DOM until the close animation
-  // ends. On WebKit the animationend/transitionend event is occasionally
-  // dropped under CI load, leaving a `data-state="closed"` backdrop attached
-  // that intercepts pointer events on subsequent actions. Wait for every
-  // dialog backdrop to be detached before continuing.
+  // Ark UI sets `data-state="closed"` synchronously on the close flag flip,
+  // but unmount only fires after `animationend`/`transitionend` — which WebKit
+  // occasionally drops under CI load. Wait on the dialog state, not on DOM
+  // detachment, so the test does not depend on the animation event firing.
+  // Any dialog part still in `data-state="open"` means a modal is active.
   public async waitForAllDialogsClosed(timeout = 15_000): Promise<void> {
-    await 
expect(this.page.locator('[data-scope="dialog"][data-part="backdrop"]')).toHaveCount(0,
 {
+    await 
expect(this.page.locator('[data-scope="dialog"][data-state="open"]')).toHaveCount(0,
 {
       timeout,
     });
   }

Reply via email to