mantimon-tcg/backend/tests
Cal Corum 2a95316f04 Add FastAPI lifespan hooks and fix Phase 1 gaps
- Add lifespan context manager to app/main.py with startup/shutdown hooks
- Wire startup: init_db(), init_redis(), CardService.load_all()
- Wire shutdown: close_db(), close_redis()
- Add /health/ready endpoint for readiness checks
- Add CORS middleware with configurable origins
- Disable docs in production (only available in dev)

- Export get_session_dependency from app/db/__init__.py for FastAPI DI
- Add game_cache_ttl_seconds to Settings (configurable, was hardcoded)
- Fix datetime.utcnow() deprecation (4 occurrences) -> datetime.now(UTC)
- Update test to match S3 image URL (was placeholder CDN)

All 974 tests passing.
2026-01-27 15:37:19 -06:00
..
core Add weakness/resistance support to attack damage calculation 2026-01-26 16:04:41 -06:00
db Add GameStateManager service with Redis/Postgres dual storage 2026-01-27 10:59:58 -06:00
scripts Add FastAPI lifespan hooks and fix Phase 1 gaps 2026-01-27 15:37:19 -06:00
services Add CardService and card data conversion pipeline 2026-01-27 14:16:40 -06:00
__init__.py Add backend foundation with uv, Black, and pre-commit hooks 2026-01-24 00:12:33 -06:00
factories.py Add database infrastructure with SQLAlchemy models and test suite 2026-01-27 10:17:30 -06:00
test_health.py Add backend foundation with uv, Black, and pre-commit hooks 2026-01-24 00:12:33 -06:00