Improve Playwright test patterns in requiredAction.spec.ts#63447
Improve Playwright test patterns in requiredAction.spec.ts#63447choo121600 merged 15 commits intoapache:mainfrom
Conversation
|
@Desel72 This PR has been converted to draft because it does not yet meet our Pull Request quality criteria. Issues found:
What to do next:
Converting a PR to draft is not a rejection — it is an invitation to bring the PR up to the project's standards so that maintainer review time is spent productively. If you have questions, feel free to ask on the Airflow Slack. |
choo121600
left a comment
There was a problem hiding this comment.
It looks like the CI is failing. Could you take a look?
29202f6 to
1d0b37e
Compare
|
@choo121600 Sorry for the ping. I’ve tried several times, but the CI tests are still failing. Could you please help me figure out what’s wrong? |
Hi! It might help to run the test locally first with: This usually catches most issues. If it still only fails in CI, checking the CI logs might help identify the cause. |
|
Feel free to ask in the Airflow Slack channel(sig-ui-e2e-tests) as well — you might get a faster response there. |
d51c252 to
51f16eb
Compare
51f16eb to
3e0ae41
Compare
|
@choo121600 I think the below CI test failure is not related my code change. could you check it? |
|
Thank you @choo121600 . All CI test passes now. could you merge this? |
airflow-core/src/airflow/ui/tests/e2e/pages/RequiredActionsPage.ts
Outdated
Show resolved
Hide resolved
airflow-core/src/airflow/ui/tests/e2e/pages/RequiredActionsPage.ts
Outdated
Show resolved
Hide resolved
airflow-core/src/airflow/ui/tests/e2e/pages/RequiredActionsPage.ts
Outdated
Show resolved
Hide resolved
|
It looks like there are still a few places where the checklist or Playwright best practices are not fully followed. |
4e35f57 to
0678473
Compare
|
@choo121600 I've updated PR and CI test passes now. could you review again? thank you |
|
@choo121600 sorry for tagging but when I test locally, it passes all CI test |
|
Don't worry. the CI failure here is not related to your code changes. |
|
@choo121600 Thank you for approving. When will this be merged? |
airflow-core/src/airflow/ui/tests/e2e/pages/RequiredActionsPage.ts
Outdated
Show resolved
Hide resolved
airflow-core/src/airflow/ui/tests/e2e/pages/RequiredActionsPage.ts
Outdated
Show resolved
Hide resolved
airflow-core/src/airflow/ui/tests/e2e/pages/RequiredActionsPage.ts
Outdated
Show resolved
Hide resolved
|
Let’s wait until the CI turns green :) |
airflow-core/src/airflow/ui/tests/e2e/pages/RequiredActionsPage.ts
Outdated
Show resolved
Hide resolved
airflow-core/src/airflow/ui/tests/e2e/pages/RequiredActionsPage.ts
Outdated
Show resolved
Hide resolved
airflow-core/src/airflow/ui/tests/e2e/pages/RequiredActionsPage.ts
Outdated
Show resolved
Hide resolved
|
@Desel72 Merged! |

Replace Playwright anti-patterns with best practices in requiredAction spec and RequiredActionsPage page object.
Changes in RequiredActionsPage.ts:
locator('[data-testid="..."]')withgetByTestId()(3 occurrences)locator("table tbody tr")with role-basedgetByRole("row")waitForTimeout(10_000)arbitrary delay after HITL responseChanges in requiredAction.spec.ts:
locator('th:has-text("...")')withgetByRole("columnheader", { exact: true, name: "..." })(5 occurrences)isVisible()boolean assertions with web-first.or()locator patterncloses: #63432