-
Notifications
You must be signed in to change notification settings - Fork 615
[TESTING][REGRESSION]: Add regression tests for gateway namespacing constraints #2520
Copy link
Copy link
Closed
Copy link
Labels
SHOULDP2: Important but not vital; high-value items that are not crucial for the immediate releaseP2: Important but not vital; high-value items that are not crucial for the immediate releasepythonPython / backend development (FastAPI)Python / backend development (FastAPI)test-automationAutomated testingAutomated testingwxowxo integrationwxo integration
Milestone
Description
Context
PR #2507 updated unique constraints for Resources and Prompts to include gateway_id, allowing the same uri/name to exist across different gateways for the same team/owner.
Missing Test Coverage
1. Resources - Gateway Namespacing
- Test: Same
urican be registered for different gateways (same team/owner) - Test: Same
uricannot be registered for the same gateway (same team/owner) - Test: Local resources (
gateway_id=NULL) still enforce uniqueness per team/owner
2. Prompts - Gateway Namespacing
- Test: Same
namecan be registered for different gateways (same team/owner) - Test: Same
namecannot be registered for the same gateway (same team/owner) - Test: Local prompts (
gateway_id=NULL) still enforce uniqueness per team/owner
3. Migration Idempotency
- Test: Migration can run on fresh DB (tables from models.py)
- Test: Migration can run on existing DB (upgrade path)
- Test: Migration downgrade works correctly
Suggested Test Location
tests/unit/mcpgateway/services/test_resource_service.pytests/unit/mcpgateway/services/test_prompt_service.pytests/unit/mcpgateway/db/(for migration tests)
Related
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
SHOULDP2: Important but not vital; high-value items that are not crucial for the immediate releaseP2: Important but not vital; high-value items that are not crucial for the immediate releasepythonPython / backend development (FastAPI)Python / backend development (FastAPI)test-automationAutomated testingAutomated testingwxowxo integrationwxo integration