Add e2e tests for Planner callback → geometry stored atomically

Introduces two E2E=true-gated test endpoints:
- POST /api/e2e/seed — creates a test user + bare route, returns routeId + JWT
- GET /api/e2e/route/:id — returns { hasGeom } for post-callback assertions

Three new integration tests:
- valid GPX via callback stores geometry (hasGeom = true)
- invalid GPX (< 2 track points) returns 400, geometry not stored
- missing token returns 401

CI: E2E=true added to the "Run E2E tests" step so the seed endpoints
are enabled when react-router-serve runs during the Playwright job.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
Ullrich Schäfer 2026-05-10 15:18:33 +02:00
parent 4189187dd4
commit e7a0c132b9
No known key found for this signature in database
GPG key ID: A32FF691A0F752D9
5 changed files with 169 additions and 1 deletions

View file

@ -231,6 +231,7 @@ jobs:
run: pnpm test:e2e
env:
BROUTER_URL: http://localhost:17777
E2E: "true"
- name: Playwright job summary
if: ${{ !cancelled() }}