Skip to content
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

CP-48198: test_filter_xapi_clusterd_db.py: Self-test asserting the expected output #104

Conversation

bernhardkaindl
Copy link
Collaborator

@bernhardkaindl bernhardkaindl commented Mar 28, 2024

test_filter_xapi_clusterd_db.py: Self-test asserting the expected output

The motivation for this PR is that I wanted to confirm that the clusterd secrets are really removed from the collected clusterd database data in the context of the question on another PR were we are looking at the clusterd on whether we can rely on the status-report to really safely filter the secrets in the cluster DB.

To double-check that we can rely on the checks in test_filter_xapi_clusterd_db.py, I reviewed them again to ensure that they work as required.

Changes:

  • Merges test_pems_blobs() and test_remove_token() into test_removal_of_all_secrets()

  • Adds new self-tests:

    • test_assertion_on_unexpected_token() (Check assert on token that is not expected)
    • test_assertion_on_unexpected_authkey() (Check assert on authkey that is not expected)

    These verify that the common test function assert_filter_xapi_clusterd_db() really detect if the output is not filtered properly.

Signed-off-by: Bernhard Kaindl <bernhard.kaindl@cloud.com>
@bernhardkaindl bernhardkaindl changed the title test_filter_xapi_clusterd_db.py: Self-test asserting the expected output CP-48198: test_filter_xapi_clusterd_db.py: Self-test asserting the expected output Mar 29, 2024
@bernhardkaindl bernhardkaindl added the Testing to guarantee proper implementation Testing to guarantee proper implementation label Mar 30, 2024
@xenserver xenserver deleted a comment from codecov bot Apr 3, 2024
@xenserver xenserver deleted a comment from coveralls Apr 3, 2024
@bernhardkaindl bernhardkaindl merged commit f9401d1 into xenserver:master Apr 4, 2024
13 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Testing to guarantee proper implementation Testing to guarantee proper implementation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants