-
Notifications
You must be signed in to change notification settings - Fork 32
🎨E2E: playwright improvements #7500
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
🎨E2E: playwright improvements #7500
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #7500 +/- ##
==========================================
+ Coverage 87.44% 87.46% +0.01%
==========================================
Files 1741 1734 -7
Lines 67375 67185 -190
Branches 1142 1142
==========================================
- Hits 58917 58763 -154
+ Misses 8138 8104 -34
+ Partials 320 318 -2
Continue to review full report in Codecov by Sentry.
🚀 New features to boost your workflow:
|
fix timeouts
44f264a to
0dd64f9
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.
Copilot reviewed 11 out of 11 changed files in this pull request and generated 1 comment.
packages/pytest-simcore/src/pytest_simcore/helpers/playwright.py
Outdated
Show resolved
Hide resolved
matusdrobuliak66
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.
Thanks a lot 🥇
odeimaiz
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.
Congratulations 🥳
pcrespov
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.
paired review. great job. Left some comments
packages/pytest-simcore/src/pytest_simcore/helpers/playwright.py
Outdated
Show resolved
Hide resolved
|



What do these changes do?
This pull request includes several changes aimed at improving the robustness and functionality of the WebSocket handling in the
pytest-simcorepackage, as well as adding new utility functions for service endpoint checking. The most important changes include renaming theRestartableWebSocketclass toRobustWebSocket, adding retry logic for WebSocket reconnections, and introducing new functions to check and wait for service endpoints.Improvements to WebSocket handling:
RestartableWebSocketclass toRobustWebSocketand added theauto_reconnectattribute to enable automatic reconnections._attempt_reconnectmethod using thetenacitylibrary to handle reconnections more robustly.test_robust_websocket.pytest to test the RobustWebSocketuv initand adding some missing libraries (currently only for that test), note that the pytest-simcore library is not CI tested.Service endpoint checking:
_get_service_urland_check_service_endpointfunctions to validate and check the readiness of service endpoints. [1] [2]wait_for_service_endpoint_respondingfunction to emulate frontend polling until the service endpoint responds with a 2xx/3xx status code.SocketIONodeProgressCompleteWaiteras this is incompatible with fast returning function called in separate threadsCode cleanup and refactoring:
assert_service_readymethod and related attributes from theSocketIONodeProgressCompleteWaiterclass, as the new service endpoint checking functions handle these checks.RobustWebSocketclass and the new service endpoint checking logic. [1] [2]Related issue/s
How to test
Dev-ops checklist