preflight
Runs a multi-phase connectivity test against the given destination.
The test checks:
- Signaling — WebSocket connected, RTT measurement
- Devices — getUserMedia succeeds with selected (or specified) devices
- ICE/TURN — gathers ICE candidates to verify STUN/TURN reachability
- Media/bandwidth (unless
skipMediaTest) — dials the destination, collects getStats() fordurationseconds, computes bandwidth estimates
Parameters
destination
A destination to dial for the media test (e.g. '/private/network-test').
options
Preflight options (duration, skipMediaTest, device overrides). See PreflightOptions.
Returns
Promise<PreflightResult>
A PreflightResult describing connectivity health.