-
Notifications
You must be signed in to change notification settings - Fork 16
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
working example #78
Open
Veritogen
wants to merge
33
commits into
CFMTech:master
Choose a base branch
from
einhundert:postgres-DB-handler
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
working example #78
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
properly close the connections on drop/garbage collection
properly close the connections on drop/garbage collection
…es not worth own commit) Merge branch 'postgres-DB-handler' of github.com:einhundert/pytest-monitor into postgres-DB-handler
with-context: Remove the with-contexts inside the PostgresDBHandler and do manual commit after cursor execution instead to prevent closing of the database connection. db-close: Add close() function to both db-handlers and the PytestMonitorSession class in order to properly close all database connections at the end of the tests. This happens in pytest-monitor.py with the pytest_sessionfinish hook implementation that calls the close() function on the PytestMonitorSession object. env-id: The query for the env-id PostgresDBHandler.get_env_id() queries for the env id in the database and gets a tuple from the query but does return it without unwrapping the value inside. This leads to problems as the value is meant to be unwrapped, therefore return the unwrapped value.
This is a helper function for generating a session description in session.py.
after tests are done.
The session is tested for proper closing of the database connection. The close() function is called from the hookimplementation in pytest_sessionfinish(). The dbhandlers are tested for proper setup of the tables and in consequence a working connection. The PostgresDBHandler requires a running postgres server, that's what the docker-compose.yml file is for
Merge with upstream master and update changelog.rst
@js-dieu we also didn't set a release in the changelog.rst and just added "to be discussed". Will you set the release number or should we add something there? |
Quality Gate failedFailed conditions |
…nitor into postgres-DB-handler
Notice: The quality gate failed because of literal passwords for the testing environment (which should not be a security issue as its only for testing purposes) |
…nitor into postgres-DB-handler
lhpt2
approved these changes
Jun 18, 2024
lhpt2
approved these changes
Jun 18, 2024
The memory profiler only reports Exceptions when it should report all Exceptions that inherit from BaseExceptions. This is ultimately reworked in a PR incorporating a simplified memory profiler module into the codebase that fixes not only this issue but also gives the possibility of getting measurements for failing tests. This workaround uses return values to work around the issue. This way pytest-monitor can check for BaseExceptions and act accordingly. Like described earlier the ultimate goal should probably be to replace the whole memory profiler as proposed in this PR: CFMTech#82
12 tasks
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
Fixes #77
Type of change
Checklist:
create one !)
Status: Code Review Needed
,Business: Test Needed
orStatus: In Progress
if you are still working on the PR)@js-dieu I'd be grateful for your input (also on the questions I posed in the issue mentioned above).