• Emit a worker event that expects a single correlated completion from the main process.

    Parameters

    • event: string

      Handler key on the parent UdsTester (e.g. 'someipApi', 'serialPortApi', 'output').

    • data: any

      Inner payload forwarded to that handler (the worker automatically assigns payload.id from global.cmdId before incrementing it).

    Returns Promise<any>

    Promise settled when the parent calls __eventDone with the same id, or rejected if the parent reports err.

    Typical pattern:

    emitWorkerEventWithReply('someipApi', { op: 'request', msg: { ... } })
    

    Submodule someip.ts uses a lazy require('./uds') + this helper to avoid circular static imports while still participating in the same emitMap lifecycle as output.