-
Notifications
You must be signed in to change notification settings - Fork 16.4k
Add E2E tests for DAG audit log functionality (#59684) #59734
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
Congratulations on your first Pull Request and welcome to the Apache Airflow community! If you have any issues or are unsure about any anything please check our Contributors' Guide (https://github.com/apache/airflow/blob/main/contributing-docs/README.rst)
|
|
@haseebmalik18 can you look at failures? |
|
Yes, I've taken a look I understand what the issue is I will have it in a day or two |
|
@vatsrahul1001 Just made the fixes. Should be good now. |
airflow-core/src/airflow/ui/tests/e2e/specs/dag-audit-log.spec.ts
Outdated
Show resolved
Hide resolved
airflow-core/src/airflow/ui/tests/e2e/specs/dag-audit-log.spec.ts
Outdated
Show resolved
Hide resolved
airflow-core/src/airflow/ui/tests/e2e/specs/dag-audit-log.spec.ts
Outdated
Show resolved
Hide resolved
airflow-core/src/airflow/ui/tests/e2e/specs/dag-audit-log.spec.ts
Outdated
Show resolved
Hide resolved
|
@haseebmalik18 can you look at review comments? |
|
@vatsrahul1001 The E2E test for audit log pagination currently creates 4 events via 3 DAG triggers, but the UI config sets page_size: 15, so pagination won't trigger. To properly test pagination, we'd need 16+ events, which would require ~14+ DAG triggers which would be quite slow. What would you say is the recommended approach for generating event logs to generate pagination direct DB inserts, lower page_size config for tests, or another method? |
|
@haseebmalik18 Thanks for working on this! Few things to address:
Let me know if you have questions! |
|
@vatsrahul1001 Made all the changes |
|
@haseebmalik18 I see chrome test are flaky. It passed on retry. Can you look into this? |
|
@vatsrahul1001 Made the fix |
|
@vatsrahul1001 The chrome test is passing now. That failed test looks like it's from a different test suite, is that unrelated to our UI testing? |
airflow-core/src/airflow/ui/tests/e2e/specs/dag-audit-log.spec.ts
Outdated
Show resolved
Hide resolved
airflow-core/src/airflow/ui/tests/e2e/specs/dag-audit-log.spec.ts
Outdated
Show resolved
Hide resolved
@haseebmalik18 PR looking in good shape. Nice work!. A few minor comments for the test case rename. I have re-run tests |
|
@vatsrahul1001 Made the test case rename changes. Also I was wondering since I made a bunch of commits will it auto squash into one commit? |
airflow-core/src/airflow/ui/tests/e2e/specs/dag-audit-log.spec.ts
Outdated
Show resolved
Hide resolved
airflow-core/src/airflow/ui/tests/e2e/specs/dag-audit-log.spec.ts
Outdated
Show resolved
Hide resolved
airflow-core/src/airflow/ui/tests/e2e/specs/dag-audit-log.spec.ts
Outdated
Show resolved
Hide resolved
airflow-core/src/airflow/ui/tests/e2e/specs/dag-audit-log.spec.ts
Outdated
Show resolved
Hide resolved
|
@vatsrahul1001 Made the changes |
|
Awesome work, congrats on your first merged pull request! You are invited to check our Issue Tracker for additional contributions. |
… PR pattern - Remove LoginPage import and all login-related code - Tests now receive authenticated page from Playwright's global storageState - Initialize DagsPage directly in each test function - Matches pattern from successfully merged PRs: apache#59943, apache#59919, apache#59734 - Fixes CI failures across Chromium, Firefox, and WebKit Addresses reviewer feedback from @vatsrahul1001
…59734) Add E2E tests for DAG audit log functionality Co-authored-by: Rahul Vats <43964496+vatsrahul1001@users.noreply.github.com>
Add E2E tests for DAG audit log functionality
This PR implements comprehensive end-to-end tests for the DAG audit log feature to ensure proper functionality of the Events tab.
Changes
New Files
airflow-core/src/airflow/ui/tests/e2e/pages/EventsPage.ts- Page Object Model for the Events/audit log pageairflow-core/src/airflow/ui/tests/e2e/specs/dag-audit-log.spec.ts- E2E test specificationsTest Coverage
The implementation includes 5 test scenarios covering:
closes: #59684