Add architecture rule that detects when API routes import database models directly, enforcing Routes → Services → Models pattern. Changes: - Add API-007 rule to .architecture-rules/api.yaml - Add _check_no_model_imports() validation to validator script - Update customer imports to use canonical module location - Add storefront module restructure implementation plan The validator now detects 81 violations across 67 API files where database models are imported directly instead of going through services. This is Phase 1 of the storefront restructure plan. Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
API v1 Integration Tests
Documentation
For comprehensive test structure documentation, please see:
Test Structure Guide in MkDocs
Quick Start
# Run all v1 API tests
pytest tests/integration/api/v1/ -v
# Run specific area
pytest tests/integration/api/v1/vendor/ -v
pytest tests/integration/api/v1/admin/ -v
pytest tests/integration/api/v1/public/ -v
pytest tests/integration/api/v1/shared/ -v
Structure
tests/integration/api/v1/
├── admin/ # Admin API tests
├── vendor/ # Vendor API tests
├── public/ # Public API tests
└── shared/ # Shared/common tests
See full documentation: Test Structure Guide