The harness uses @beignet/web under the hood, so tests exercise the same
request parsing, route hooks, response validation, and error ownership as a
Web Fetch runtime without requiring Next.js or a network listener.
Test-friendly defaults differ from production servers in two ways, and an
explicit option always wins:
onUnboundPorts defaults to "ignore" so apps with deferred provider
ports boot without installing every provider. Reading an unbound port
still throws on use.
mapUnhandledError defaults to a mapper that surfaces err.message in
the 500 response body so failing tests show the real error.
Create a Beignet route/runtime test harness.
The harness uses
@beignet/webunder the hood, so tests exercise the same request parsing, route hooks, response validation, and error ownership as a Web Fetch runtime without requiring Next.js or a network listener.Test-friendly defaults differ from production servers in two ways, and an explicit option always wins:
onUnboundPortsdefaults to"ignore"so apps with deferred provider ports boot without installing every provider. Reading an unbound port still throws on use.mapUnhandledErrordefaults to a mapper that surfaceserr.messagein the 500 response body so failing tests show the real error.