testing/bootstrap_success.ts

Bootstrap success-path suite for consumer projects.

Exercises POST /bootstrap against an empty DB (no pre-keeper, lock unflipped) through the real bootstrap_account flow. Asserts on observable state — account exists, bootstrap_lock.bootstrapped is true, audit row emitted, response body shape — rather than on_bootstrap callback invocation, so the suite stays cross-impl friendly when cross-process testing wires it against a spawned Rust backend.

Folded into describe_standard_tests with a bootstrap.mode === 'live' silent-skip gate; consumers wiring live bootstrap pick up success-path coverage by default.

Declarations
#

2 declarations

view source

BootstrapSuccessTestOptions
#

testing/bootstrap_success.ts view source

BootstrapSuccessTestOptions

session_options

type SessionOptions<string>

create_route_specs

Same factory the consumer's production server uses.

type (ctx: AppServerContext) => Array<RouteSpec>

rpc_endpoints

RPC endpoints — passed through to create_app_server for shape parity.

bootstrap

Live bootstrap config — the suite drives POST /bootstrap against bootstrap.token_path. The suite does NOT assert on on_bootstrap callback invocation (Hono-coupled signature is in-process only); assertions land on observable DB state.

bootstrap_token

Override the synthetic token text. Default deterministic.

type string

describe_bootstrap_success_tests
#

Depends on
#

Imported by
#