mirror of
https://github.com/bitbaum/loki.git
synced 2026-12-04 10:27:56 +01:00
Status-only smoke missed a real failure mode: when a Server Component
throws, Next.js renders src/app/error.tsx ("Something went wrong")
INSIDE a 200 response. The page is broken from the user's perspective,
but smoke would mark it ok.
Refactor into a check_route helper that pages call with body-content
checking enabled. Greps the response body for the error-boundary
marker; failing-when-found means the run page doubles as a sanity
check on every server component, not just the route resolver.
API routes skip the body check (the marker is HTML-only and an API
that returned the literal string would be unusual).
Verified: all 18 routes still pass; the grep would catch a fake
error response if one were served.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>