-
Notifications
You must be signed in to change notification settings - Fork 78
fix(FR-1711): showNonInstalledImages E2E test #4679
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
How to use the Graphite Merge QueueAdd either label to this PR to merge it via the merge queue:
You must have a Graphite account in order to use the merge queue. Sign up using this link. An organization admin has required the Graphite Merge Queue in this repository. Please do not merge from GitHub as this will restart CI on PRs being processed by the merge queue. This stack of pull requests is managed by Graphite. Learn more about stacking. |
0427c31 to
acfddfa
Compare
afbdc97 to
9370c0b
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR refactors the showNonInstalledImages E2E test to improve reliability and performance by replacing clipboard-based operations with direct DOM inspection and implementing the Page Object Pattern.
Key Changes
- Replaced fragile clipboard copy/paste operations with direct DOM element inspection to identify uninstalled images
- Integrated
StartPageclass for better code organization following Page Object Pattern - Improved test execution time from 20.9s to 8.1s by removing unnecessary
waitForTimeoutcalls
d4f5f24 to
ddaf3cf
Compare
nowgnuesLee
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Merge activity
|
Resolves FR-1711 ## Summary This PR fix and refactors the `showNonInstalledImages` E2E test in `e2e/config.test.ts` to improve reliability and maintainability. ## Changes ### Test Improvements - **Removed clipboard-based approach**: Previously, the test used complex clipboard copy/paste operations which were fragile. Now directly inspects DOM elements. - **Better selector strategy**: Uses semantic selectors and excludes `ant-table-measure-row` elements that caused false positives. - **Page Object Pattern**: Integrated `StartPage` class for better code organization and reusability. - **Removed unnecessary waits**: Eliminated all `waitForTimeout` calls, relying on Playwright's built-in auto-waiting mechanism. - **More reliable image detection**: Changed from checking badges to checking empty status cells to identify uninstalled images. ### Performance - Test execution time improved from **20\.9s to 8.1s** after removing unnecessary timeouts. ### Code Quality - Applied Page Object Pattern with `StartPage` class - Used explicit waits only when necessary (`waitForSelector`) - Added proper element state checks (`state: 'attached'`) - Used force click option to avoid element interception issues ## Test Plan Run the specific test: ```bash pnpm exec playwright test e2e/config.test.ts -g "showNonInstalledImages" ``` The test should: 1. Log in as admin 2. Navigate to Environments page 3. Find an uninstalled image (empty status cell) 4. Navigate to Start/Session launcher 5. Open environment selector 6. Search for the uninstalled image 7. Verify the image appears in the dropdown (selectable) **Checklist:** - [x] Test execution time improved - [x] Test reliability improved (no flaky timeouts) - [x] Code maintainability improved (Page Object Pattern) - [x] Proper Playwright patterns (auto-waiting, semantic selectors)
ddaf3cf to
e03712d
Compare

Resolves FR-1711
Summary
This PR fix and refactors the
showNonInstalledImagesE2E test ine2e/config.test.tsto improve reliability and maintainability.Changes
Test Improvements
ant-table-measure-rowelements that caused false positives.StartPageclass for better code organization and reusability.waitForTimeoutcalls, relying on Playwright's built-in auto-waiting mechanism.Performance
Code Quality
StartPageclasswaitForSelector)state: 'attached')Test Plan
Run the specific test:
The test should:
Checklist: