OptionalclockClock used for timestamps. Default: Date.now.
OptionalechoEcho transform applied to each write, or false to disable. Default mockSerialEcho.
OptionallatencyArtificial latency (ms) applied before each result. Default 0, which
responds synchronously inside handleMessage.
OptionalportsPorts to seed. Default MOCK_SERIAL_PORTS.
OptionalschedulerScheduler used for deferred pushes. Default: setTimeout.
OptionalseedSeed for deterministic ids and fixture ordering. Default 1.
Factory options for the serial mock.
Example