-
Notifications
You must be signed in to change notification settings - Fork 32
♻️✅ Refactor webserver pytest helpers to isolate user and login setup logic #7984
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
♻️✅ Refactor webserver pytest helpers to isolate user and login setup logic #7984
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #7984 +/- ##
==========================================
- Coverage 87.85% 83.85% -4.01%
==========================================
Files 1850 1843 -7
Lines 71393 71203 -190
Branches 1254 1254
==========================================
- Hits 62725 59706 -3019
- Misses 8303 11132 +2829
Partials 365 365
Continue to review full report in Codecov by Sentry.
🚀 New features to boost your workflow:
|
|
@mergify queue |
🟠 Waiting for conditions to match
|
sanderegg
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.
oh I guess I won't like it... I am currently also updating the tools and the pytest-asyncio which is a mess in the webserver. let's check tomorrow. but feel free to merge this anyway.
|



What do these changes do?
This PR refactors the
pytest_simcore.helpers.webserver_*module by splitting it into two focused helper modules:pytest_simcore.helpers.webserver_users: for setting up/tearing down user accounts (direct DB access).pytest_simcore.helpers.webserver_login: for handling signed-in user setup/teardown.This separation reduces interdependencies and fixture requirements, making test setup more modular and maintainable.
It also eliminates legacy dependencies on
simcore_service_webserver.login._login_repository_legacy, which is deprecated.NOTE: A new
exit_stackfixture is introduced. It can be used to create unit-of-work contexts for test setup/teardown within the test.Related issue/s
simcore_service_webserver.login._login_repository_legacyis part of migrate code from aiopg to asyncpg #4529How to test
Dev-ops
None