Function mockOriginOperationId

  • Set mock for origin operation Id.

    Remarks

    This function is used to mock the origin operation Id for test purpose. If an empty string is passed, the origin operation Id will be reset to the default value (random generated). Don't forget to reset the mock after the test.

    Example

    test('mock origin opId', () => {
    const opId = 123;
    mockOriginOperationId(opId);
    const res = getOriginOperationId()();
    expect(res).toBe(opId);
    });

    Parameters

    • opId: string

    Returns void

Generated using TypeDoc