test(integration): repair pre-existing integration test failures (fully green CI)#727
Merged
Merged
Conversation
Brings the integration gate back to green (red on master independent of CI): - test_process_stats_read_609: drop shadowing viewer_token fixture (old create_access_token dict signature) and set required first_seen_at on seeded nodes - test_node_action_execution_614: add db->db_session alias fixture, set required node_token_hash/first_seen_at, pass a Request to slowapi-decorated handlers, and update the approve happy-path to the async apply_async/'executing' contract - test_process_stats_ingest: add the missing registered_node_client fixture - test_salt_keys_api: rewrite filesystem _dirs mocks for the salt-api wheel client route (key.list_all/accept/reject/delete; degraded/502 paths) - test_test_email_api: mock send_test_email since the route reads SMTP settings via an un-overridden sync session Verified locally against a disposable Postgres: 36/36 in the touched files pass.
Coverage Report✅ 85.1% on Gate passed |
This file contains hidden or 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
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.
Summary
Repairs the integration-test gate, which has been red on master independent of any single PR. None of these failures were caused by the agent epic or the dependency bump — they are accumulated test drift across several subsystems.
test_process_stats_read_609viewer_tokenfixture used the oldcreate_access_token({...})dict signature; seeded nodes missingfirst_seen_atfirst_seen_attest_node_action_execution_614dbfixture; nodes missingnode_token_hash/first_seen_at; handlers now slowapi-decorated (needRequest); approve now async (apply_async→executing)db→db_sessionalias, set required cols, pass aRequest, update to the async dispatch contracttest_process_stats_ingestregistered_node_clientfixture never definedtest_salt_keys_api_dirshelperkey.list_all/accept/reject/delete, degraded/502 paths)test_test_email_apiplatform_settingsmissing in test DBsend_test_emailto exercise the 400 pathTest plan
ruff check/ruff formatcleanMade with Cursor