app.bettersight.io/backend/tests
JasonFraser f7aaafa533 Phase 1: data foundation — schema, repositories, services, routes, jobs
Implements CLAUDE.md Build Order Phase 1 end to end:
- PocketBase migration covering all 15 MVP-scope collections
- Repository layer (11 repos) with real PocketBase-backed + in-memory
  mock implementations for every collection
- Service layer (licence, trip-finder, battlecard, embedding, brief,
  alert, analysis, onboarding, billing, auth) — Phase 2 scraping/
  extraction dependencies are lazy-imported so this layer is fully
  testable ahead of the app.py refactor
- Flask API (api.py) covering every MVP route from the spec, with
  X-API-Key auth, Flask-Limiter rate limits, and structured JSON errors
- RQ job queue (jobs.py) with per-competitor failure isolation and
  duration-based Gotify alerting
- 142 tests, 95% coverage, 100% on licence validation / seat
  management / Stripe webhook dispatch per CLAUDE.md's testing floor

/sheet/push and /sheet/tabs intentionally return structured 501s until
the Apps Script Web App deployment exists (Phase 4).

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-07-01 12:21:04 -04:00
..
repositories Phase 1: data foundation — schema, repositories, services, routes, jobs 2026-07-01 12:21:04 -04:00
services Phase 1: data foundation — schema, repositories, services, routes, jobs 2026-07-01 12:21:04 -04:00
__init__.py Phase 1: data foundation — schema, repositories, services, routes, jobs 2026-07-01 12:21:04 -04:00
conftest.py Phase 1: data foundation — schema, repositories, services, routes, jobs 2026-07-01 12:21:04 -04:00
test_api.py Phase 1: data foundation — schema, repositories, services, routes, jobs 2026-07-01 12:21:04 -04:00
test_api_extended.py Phase 1: data foundation — schema, repositories, services, routes, jobs 2026-07-01 12:21:04 -04:00