test: add unit tests for middleware, routers, cache and error handlers#2620
Merged
crivetimihai merged 1 commit intomainfrom Jan 31, 2026
Merged
test: add unit tests for middleware, routers, cache and error handlers#2620crivetimihai merged 1 commit intomainfrom
crivetimihai merged 1 commit intomainfrom
Conversation
- Add tests for RegistryCache (cache entry expiry, stats, invalidation) - Add tests for SecurityHeadersMiddleware (HSTS, CORS, CSP, X-Frame-Options) - Add tests for ValidationMiddleware (path traversal, parameter validation) - Add tests for auth router (login, get_db, LoginRequest model) - Expand metrics_maintenance router tests (cleanup, rollup, stats endpoints) - Add tests for admin error handlers (server add/edit error paths) - Add tests for main.py gateway error handlers (connection, conflict, validation) Signed-off-by: Mihai Criveti <crivetimihai@gmail.com>
hughhennelly
pushed a commit
to hughhennelly/mcp-context-forge
that referenced
this pull request
Feb 8, 2026
IBM#2620) - Add tests for RegistryCache (cache entry expiry, stats, invalidation) - Add tests for SecurityHeadersMiddleware (HSTS, CORS, CSP, X-Frame-Options) - Add tests for ValidationMiddleware (path traversal, parameter validation) - Add tests for auth router (login, get_db, LoginRequest model) - Expand metrics_maintenance router tests (cleanup, rollup, stats endpoints) - Add tests for admin error handlers (server add/edit error paths) - Add tests for main.py gateway error handlers (connection, conflict, validation) Signed-off-by: Mihai Criveti <crivetimihai@gmail.com> Signed-off-by: hughhennnelly <hughhennelly06@gmail.com>
kcostell06
pushed a commit
to kcostell06/mcp-context-forge
that referenced
this pull request
Feb 24, 2026
IBM#2620) - Add tests for RegistryCache (cache entry expiry, stats, invalidation) - Add tests for SecurityHeadersMiddleware (HSTS, CORS, CSP, X-Frame-Options) - Add tests for ValidationMiddleware (path traversal, parameter validation) - Add tests for auth router (login, get_db, LoginRequest model) - Expand metrics_maintenance router tests (cleanup, rollup, stats endpoints) - Add tests for admin error handlers (server add/edit error paths) - Add tests for main.py gateway error handlers (connection, conflict, validation) Signed-off-by: Mihai Criveti <crivetimihai@gmail.com>
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
Test plan
make coverageto verify coverage improvement