@webex/calling 3.12.0-next.32 → 3.12.0-next.34
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/CallingClient/calling/call.js +572 -452
- package/dist/CallingClient/calling/call.js.map +1 -1
- package/dist/CallingClient/calling/call.test.js +145 -31
- package/dist/CallingClient/calling/call.test.js.map +1 -1
- package/dist/CallingClient/calling/types.js.map +1 -1
- package/dist/CallingClient/constants.js +1 -0
- package/dist/CallingClient/constants.js.map +1 -1
- package/dist/Events/types.js.map +1 -1
- package/dist/Metrics/index.js +3 -2
- package/dist/Metrics/index.js.map +1 -1
- package/dist/Metrics/index.test.js +1 -1
- package/dist/Metrics/index.test.js.map +1 -1
- package/dist/Metrics/types.js +9 -1
- package/dist/Metrics/types.js.map +1 -1
- package/dist/module/CallingClient/calling/call.js +159 -61
- package/dist/module/CallingClient/constants.js +1 -0
- package/dist/module/Metrics/index.js +2 -1
- package/dist/module/Metrics/types.js +8 -0
- package/dist/types/CallingClient/calling/call.d.ts +10 -0
- package/dist/types/CallingClient/calling/call.d.ts.map +1 -1
- package/dist/types/CallingClient/calling/types.d.ts +13 -0
- package/dist/types/CallingClient/calling/types.d.ts.map +1 -1
- package/dist/types/CallingClient/constants.d.ts +1 -0
- package/dist/types/CallingClient/constants.d.ts.map +1 -1
- package/dist/types/Events/types.d.ts +4 -1
- package/dist/types/Events/types.d.ts.map +1 -1
- package/dist/types/Metrics/index.d.ts.map +1 -1
- package/dist/types/Metrics/types.d.ts +8 -1
- package/dist/types/Metrics/types.d.ts.map +1 -1
- package/package.json +3 -3
|
@@ -442,8 +442,122 @@ describe('Call Tests', function () {
|
|
|
442
442
|
}
|
|
443
443
|
}, _callee8);
|
|
444
444
|
})));
|
|
445
|
+
it('registers and unregisters media connection listeners with stable handlers', function () {
|
|
446
|
+
var mockStream = {
|
|
447
|
+
outputStream: {
|
|
448
|
+
getAudioTracks: jest.fn().mockReturnValue([mockTrack])
|
|
449
|
+
},
|
|
450
|
+
on: jest.fn(),
|
|
451
|
+
getEffectByKind: jest.fn().mockReturnValue(undefined)
|
|
452
|
+
};
|
|
453
|
+
var localAudioStream = mockStream;
|
|
454
|
+
var call = (0, _call.createCall)(activeUrl, webex, _types3.CallDirection.OUTBOUND, deviceId, mockLineId, deleteCallFromCollection, defaultServiceIndicator, dest);
|
|
455
|
+
call.dial(localAudioStream);
|
|
456
|
+
var mediaOnMock = call['mediaConnection'].on;
|
|
457
|
+
var mediaOffSpy = jest.spyOn(call['mediaConnection'], 'off');
|
|
458
|
+
expect(mediaOnMock).toBeCalledWith(InternalMediaCoreModule.MediaConnectionEventNames.ROAP_MESSAGE_TO_SEND, expect.any(Function));
|
|
459
|
+
expect(mediaOnMock).toBeCalledWith(InternalMediaCoreModule.MediaConnectionEventNames.ROAP_FAILURE, expect.any(Function));
|
|
460
|
+
expect(mediaOnMock).toBeCalledWith(InternalMediaCoreModule.MediaConnectionEventNames.REMOTE_TRACK_ADDED, expect.any(Function));
|
|
461
|
+
expect(mediaOnMock).toBeCalledWith(InternalMediaCoreModule.MediaConnectionEventNames.ICE_GATHERING_STATE_CHANGED, expect.any(Function));
|
|
462
|
+
expect(mediaOnMock).toBeCalledWith(InternalMediaCoreModule.MediaConnectionEventNames.PEER_CONNECTION_STATE_CHANGED, expect.any(Function));
|
|
463
|
+
expect(mediaOnMock).toBeCalledWith(InternalMediaCoreModule.MediaConnectionEventNames.ICE_CONNECTION_STATE_CHANGED, expect.any(Function));
|
|
464
|
+
expect(mediaOnMock).toBeCalledWith(InternalMediaCoreModule.MediaConnectionEventNames.ICE_CANDIDATE_ERROR, expect.any(Function));
|
|
465
|
+
call['unregisterMediaConnectionListeners']();
|
|
466
|
+
expect(mediaOffSpy).toBeCalledWith(InternalMediaCoreModule.MediaConnectionEventNames.ROAP_MESSAGE_TO_SEND, expect.any(Function));
|
|
467
|
+
expect(mediaOffSpy).toBeCalledWith(InternalMediaCoreModule.MediaConnectionEventNames.ROAP_FAILURE, expect.any(Function));
|
|
468
|
+
expect(mediaOffSpy).toBeCalledWith(InternalMediaCoreModule.MediaConnectionEventNames.REMOTE_TRACK_ADDED, expect.any(Function));
|
|
469
|
+
expect(mediaOffSpy).toBeCalledWith(InternalMediaCoreModule.MediaConnectionEventNames.ICE_GATHERING_STATE_CHANGED, expect.any(Function));
|
|
470
|
+
expect(mediaOffSpy).toBeCalledWith(InternalMediaCoreModule.MediaConnectionEventNames.PEER_CONNECTION_STATE_CHANGED, expect.any(Function));
|
|
471
|
+
expect(mediaOffSpy).toBeCalledWith(InternalMediaCoreModule.MediaConnectionEventNames.ICE_CONNECTION_STATE_CHANGED, expect.any(Function));
|
|
472
|
+
expect(mediaOffSpy).toBeCalledWith(InternalMediaCoreModule.MediaConnectionEventNames.ICE_CANDIDATE_ERROR, expect.any(Function));
|
|
473
|
+
});
|
|
474
|
+
it('handles ICE listener payloads and submits metrics with event names', function () {
|
|
475
|
+
var mockStream = {
|
|
476
|
+
outputStream: {
|
|
477
|
+
getAudioTracks: jest.fn().mockReturnValue([mockTrack])
|
|
478
|
+
},
|
|
479
|
+
on: jest.fn(),
|
|
480
|
+
getEffectByKind: jest.fn().mockReturnValue(undefined)
|
|
481
|
+
};
|
|
482
|
+
var localAudioStream = mockStream;
|
|
483
|
+
var call = (0, _call.createCall)(activeUrl, webex, _types3.CallDirection.OUTBOUND, deviceId, mockLineId, deleteCallFromCollection, defaultServiceIndicator, dest);
|
|
484
|
+
call.dial(localAudioStream);
|
|
485
|
+
var metricSpy = jest.spyOn(call['metricManager'], 'submitMediaMetric');
|
|
486
|
+
var warnSpy = jest.spyOn(_Logger.default, 'warn');
|
|
487
|
+
var getHandlerForEvent = function getHandlerForEvent(eventName) {
|
|
488
|
+
var _mock$calls$find;
|
|
489
|
+
return (_mock$calls$find = call['mediaConnection'].on.mock.calls.find(function (_ref9) {
|
|
490
|
+
var _ref0 = (0, _slicedToArray2.default)(_ref9, 1),
|
|
491
|
+
name = _ref0[0];
|
|
492
|
+
return name === eventName;
|
|
493
|
+
})) === null || _mock$calls$find === void 0 ? void 0 : _mock$calls$find[1];
|
|
494
|
+
};
|
|
495
|
+
var iceGatheringHandler = getHandlerForEvent(InternalMediaCoreModule.MediaConnectionEventNames.ICE_GATHERING_STATE_CHANGED);
|
|
496
|
+
var peerConnectionHandler = getHandlerForEvent(InternalMediaCoreModule.MediaConnectionEventNames.PEER_CONNECTION_STATE_CHANGED);
|
|
497
|
+
var iceConnectionHandler = getHandlerForEvent(InternalMediaCoreModule.MediaConnectionEventNames.ICE_CONNECTION_STATE_CHANGED);
|
|
498
|
+
var iceCandidateErrorHandler = getHandlerForEvent(InternalMediaCoreModule.MediaConnectionEventNames.ICE_CANDIDATE_ERROR);
|
|
499
|
+
iceGatheringHandler({
|
|
500
|
+
iceGatheringState: 'gathering'
|
|
501
|
+
});
|
|
502
|
+
peerConnectionHandler({
|
|
503
|
+
connectionState: 'connected'
|
|
504
|
+
});
|
|
505
|
+
iceConnectionHandler({
|
|
506
|
+
iceConnectionState: 'completed'
|
|
507
|
+
});
|
|
508
|
+
iceCandidateErrorHandler({
|
|
509
|
+
errorCode: 701,
|
|
510
|
+
errorText: 'STUN host lookup failed',
|
|
511
|
+
url: 'stun:example.org:3478'
|
|
512
|
+
});
|
|
513
|
+
expect(metricSpy).toHaveBeenNthCalledWith(1, _types4.METRIC_EVENT.MEDIA, _types4.MEDIA_CONNECTION_ACTION.ICE_GATHERING_STATE_CHANGED, _types4.METRIC_TYPE.BEHAVIORAL, call.getCallId(), call.getCorrelationId(), undefined, undefined, 'gathering');
|
|
514
|
+
expect(metricSpy).toHaveBeenNthCalledWith(2, _types4.METRIC_EVENT.MEDIA, _types4.MEDIA_CONNECTION_ACTION.PEER_CONNECTION_STATE_CHANGED, _types4.METRIC_TYPE.BEHAVIORAL, call.getCallId(), call.getCorrelationId(), undefined, undefined, 'connected');
|
|
515
|
+
expect(metricSpy).toHaveBeenNthCalledWith(3, _types4.METRIC_EVENT.MEDIA, _types4.MEDIA_CONNECTION_ACTION.ICE_CONNECTION_STATE_CHANGED, _types4.METRIC_TYPE.BEHAVIORAL, call.getCallId(), call.getCorrelationId(), undefined, undefined, 'completed');
|
|
516
|
+
expect(metricSpy).toHaveBeenNthCalledWith(4, _types4.METRIC_EVENT.MEDIA_ERROR, _types4.MEDIA_CONNECTION_ACTION.ICE_CANDIDATE_ERROR, _types4.METRIC_TYPE.BEHAVIORAL, call.getCallId(), call.getCorrelationId(), undefined, undefined, undefined, expect.any(_Errors.CallError));
|
|
517
|
+
var mediaErrorCall = metricSpy.mock.calls[3];
|
|
518
|
+
expect(mediaErrorCall[mediaErrorCall.length - 1].getCallError().message).toBe('ICE candidate error occurred: {"address":null,"errorCode":701,"errorText":"STUN host lookup failed","port":null,"url":"stun:example.org:3478"}');
|
|
519
|
+
expect(warnSpy).toHaveBeenCalledWith('ICE candidate error occurred: {"address":null,"errorCode":701,"errorText":"STUN host lookup failed","port":null,"url":"stun:example.org:3478"}', {
|
|
520
|
+
file: 'call',
|
|
521
|
+
method: 'mediaIceEventsListener'
|
|
522
|
+
});
|
|
523
|
+
});
|
|
524
|
+
it('handles ROAP failure listener and submits media error metric', function () {
|
|
525
|
+
var _mock$calls$find2;
|
|
526
|
+
var mockStream = {
|
|
527
|
+
outputStream: {
|
|
528
|
+
getAudioTracks: jest.fn().mockReturnValue([mockTrack])
|
|
529
|
+
},
|
|
530
|
+
on: jest.fn(),
|
|
531
|
+
getEffectByKind: jest.fn().mockReturnValue(undefined)
|
|
532
|
+
};
|
|
533
|
+
var localAudioStream = mockStream;
|
|
534
|
+
var call = (0, _call.createCall)(activeUrl, webex, _types3.CallDirection.OUTBOUND, deviceId, mockLineId, deleteCallFromCollection, defaultServiceIndicator, dest);
|
|
535
|
+
call.dial(localAudioStream);
|
|
536
|
+
var metricSpy = jest.spyOn(call['metricManager'], 'submitMediaMetric');
|
|
537
|
+
var warnSpy = jest.spyOn(_Logger.default, 'warn');
|
|
538
|
+
var roapFailureHandler = (_mock$calls$find2 = call['mediaConnection'].on.mock.calls.find(function (_ref1) {
|
|
539
|
+
var _ref10 = (0, _slicedToArray2.default)(_ref1, 1),
|
|
540
|
+
name = _ref10[0];
|
|
541
|
+
return name === InternalMediaCoreModule.MediaConnectionEventNames.ROAP_FAILURE;
|
|
542
|
+
})) === null || _mock$calls$find2 === void 0 ? void 0 : _mock$calls$find2[1];
|
|
543
|
+
var roapFailure = new Error('Failed to process remote SDP');
|
|
544
|
+
roapFailureHandler(roapFailure);
|
|
545
|
+
expect(metricSpy).toHaveBeenCalledWith(_types4.METRIC_EVENT.MEDIA_ERROR, _types4.MEDIA_CONNECTION_ACTION.ROAP_FAILURE, _types4.METRIC_TYPE.BEHAVIORAL, call.getCallId(), call.getCorrelationId(), undefined, undefined, undefined, expect.any(_Errors.CallError));
|
|
546
|
+
var roapFailureMetricCall = metricSpy.mock.calls.find(function (_ref11) {
|
|
547
|
+
var _ref12 = (0, _slicedToArray2.default)(_ref11, 2),
|
|
548
|
+
name = _ref12[0],
|
|
549
|
+
metricAction = _ref12[1];
|
|
550
|
+
return name === _types4.METRIC_EVENT.MEDIA_ERROR && metricAction === _types4.MEDIA_CONNECTION_ACTION.ROAP_FAILURE;
|
|
551
|
+
});
|
|
552
|
+
expect(roapFailureMetricCall).toBeDefined();
|
|
553
|
+
expect((roapFailureMetricCall === null || roapFailureMetricCall === void 0 ? void 0 : roapFailureMetricCall[roapFailureMetricCall.length - 1]).getCallError().message).toBe('ROAP failure occurred: Failed to process remote SDP');
|
|
554
|
+
expect(warnSpy).toHaveBeenCalledWith('ROAP failure occurred: Failed to process remote SDP', {
|
|
555
|
+
file: 'call',
|
|
556
|
+
method: 'mediaRoapEventsListener'
|
|
557
|
+
});
|
|
558
|
+
});
|
|
445
559
|
it('sends connect before ROAP answer when inbound offer is delayed', /*#__PURE__*/(0, _asyncToGenerator2.default)(/*#__PURE__*/_regenerator.default.mark(function _callee9() {
|
|
446
|
-
var _mock$calls$
|
|
560
|
+
var _mock$calls$find3;
|
|
447
561
|
var mockStream, localAudioStream, call, handleOutgoingCallConnectSpy, delayedOffer, sendCallStateMachineEvtSpy, sendMediaStateMachineEvtSpy, roapListener;
|
|
448
562
|
return _regenerator.default.wrap(function (_context9) {
|
|
449
563
|
while (1) switch (_context9.prev = _context9.next) {
|
|
@@ -498,11 +612,11 @@ describe('Call Tests', function () {
|
|
|
498
612
|
expect(call['mediaConnection'].roapMessageReceived).toHaveBeenCalledWith(delayedOffer);
|
|
499
613
|
sendCallStateMachineEvtSpy = jest.spyOn(call, 'sendCallStateMachineEvt');
|
|
500
614
|
sendMediaStateMachineEvtSpy = jest.spyOn(call, 'sendMediaStateMachineEvt');
|
|
501
|
-
roapListener = (_mock$calls$
|
|
502
|
-
var
|
|
503
|
-
eventName =
|
|
615
|
+
roapListener = (_mock$calls$find3 = call['mediaConnection'].on.mock.calls.find(function (_ref14) {
|
|
616
|
+
var _ref15 = (0, _slicedToArray2.default)(_ref14, 1),
|
|
617
|
+
eventName = _ref15[0];
|
|
504
618
|
return eventName === InternalMediaCoreModule.MediaConnectionEventNames.ROAP_MESSAGE_TO_SEND;
|
|
505
|
-
})) === null || _mock$calls$
|
|
619
|
+
})) === null || _mock$calls$find3 === void 0 ? void 0 : _mock$calls$find3[1];
|
|
506
620
|
expect(roapListener).toBeDefined();
|
|
507
621
|
_context9.next = 3;
|
|
508
622
|
return roapListener({
|
|
@@ -2727,7 +2841,7 @@ describe('Supplementary Services tests', function () {
|
|
|
2727
2841
|
warnSpy = jest.spyOn(_Logger.default, 'warn');
|
|
2728
2842
|
call['held'] = false;
|
|
2729
2843
|
call.on(_types2.CALL_EVENT_KEYS.HELD, /*#__PURE__*/function () {
|
|
2730
|
-
var
|
|
2844
|
+
var _ref54 = (0, _asyncToGenerator2.default)(/*#__PURE__*/_regenerator.default.mark(function _callee45(correlationId) {
|
|
2731
2845
|
return _regenerator.default.wrap(function (_context45) {
|
|
2732
2846
|
while (1) switch (_context45.prev = _context45.next) {
|
|
2733
2847
|
case 0:
|
|
@@ -2739,7 +2853,7 @@ describe('Supplementary Services tests', function () {
|
|
|
2739
2853
|
}, _callee45);
|
|
2740
2854
|
}));
|
|
2741
2855
|
return function (_x) {
|
|
2742
|
-
return
|
|
2856
|
+
return _ref54.apply(this, arguments);
|
|
2743
2857
|
};
|
|
2744
2858
|
}());
|
|
2745
2859
|
_context46.next = 1;
|
|
@@ -2800,7 +2914,7 @@ describe('Supplementary Services tests', function () {
|
|
|
2800
2914
|
warnSpy = jest.spyOn(_Logger.default, 'warn');
|
|
2801
2915
|
call['held'] = false;
|
|
2802
2916
|
call.on(_types2.CALL_EVENT_KEYS.HELD, /*#__PURE__*/function () {
|
|
2803
|
-
var
|
|
2917
|
+
var _ref56 = (0, _asyncToGenerator2.default)(/*#__PURE__*/_regenerator.default.mark(function _callee47(correlationId) {
|
|
2804
2918
|
return _regenerator.default.wrap(function (_context47) {
|
|
2805
2919
|
while (1) switch (_context47.prev = _context47.next) {
|
|
2806
2920
|
case 0:
|
|
@@ -2812,7 +2926,7 @@ describe('Supplementary Services tests', function () {
|
|
|
2812
2926
|
}, _callee47);
|
|
2813
2927
|
}));
|
|
2814
2928
|
return function (_x2) {
|
|
2815
|
-
return
|
|
2929
|
+
return _ref56.apply(this, arguments);
|
|
2816
2930
|
};
|
|
2817
2931
|
}());
|
|
2818
2932
|
call.doHoldResume();
|
|
@@ -2871,7 +2985,7 @@ describe('Supplementary Services tests', function () {
|
|
|
2871
2985
|
jest.spyOn(webex, 'request').mockRejectedValue(responsePayload);
|
|
2872
2986
|
call['held'] = false;
|
|
2873
2987
|
call.on(_types2.CALL_EVENT_KEYS.HOLD_ERROR, /*#__PURE__*/function () {
|
|
2874
|
-
var
|
|
2988
|
+
var _ref58 = (0, _asyncToGenerator2.default)(/*#__PURE__*/_regenerator.default.mark(function _callee49(errObj) {
|
|
2875
2989
|
return _regenerator.default.wrap(function (_context49) {
|
|
2876
2990
|
while (1) switch (_context49.prev = _context49.next) {
|
|
2877
2991
|
case 0:
|
|
@@ -2884,7 +2998,7 @@ describe('Supplementary Services tests', function () {
|
|
|
2884
2998
|
}, _callee49);
|
|
2885
2999
|
}));
|
|
2886
3000
|
return function (_x3) {
|
|
2887
|
-
return
|
|
3001
|
+
return _ref58.apply(this, arguments);
|
|
2888
3002
|
};
|
|
2889
3003
|
}());
|
|
2890
3004
|
_context50.next = 1;
|
|
@@ -2921,7 +3035,7 @@ describe('Supplementary Services tests', function () {
|
|
|
2921
3035
|
jest.spyOn(webex, 'request').mockResolvedValueOnce(responsePayload).mockRejectedValueOnce(rejectPayload);
|
|
2922
3036
|
call['held'] = false;
|
|
2923
3037
|
call.on(_types2.CALL_EVENT_KEYS.HOLD_ERROR, /*#__PURE__*/function () {
|
|
2924
|
-
var
|
|
3038
|
+
var _ref60 = (0, _asyncToGenerator2.default)(/*#__PURE__*/_regenerator.default.mark(function _callee51(errObj) {
|
|
2925
3039
|
return _regenerator.default.wrap(function (_context51) {
|
|
2926
3040
|
while (1) switch (_context51.prev = _context51.next) {
|
|
2927
3041
|
case 0:
|
|
@@ -2934,7 +3048,7 @@ describe('Supplementary Services tests', function () {
|
|
|
2934
3048
|
}, _callee51);
|
|
2935
3049
|
}));
|
|
2936
3050
|
return function (_x4) {
|
|
2937
|
-
return
|
|
3051
|
+
return _ref60.apply(this, arguments);
|
|
2938
3052
|
};
|
|
2939
3053
|
}());
|
|
2940
3054
|
call.doHoldResume();
|
|
@@ -3088,7 +3202,7 @@ describe('Supplementary Services tests', function () {
|
|
|
3088
3202
|
jest.spyOn(webex, 'request').mockResolvedValue(responsePayload);
|
|
3089
3203
|
call['held'] = false;
|
|
3090
3204
|
call.on(_types2.CALL_EVENT_KEYS.HOLD_ERROR, /*#__PURE__*/function () {
|
|
3091
|
-
var
|
|
3205
|
+
var _ref64 = (0, _asyncToGenerator2.default)(/*#__PURE__*/_regenerator.default.mark(function _callee55(errObj) {
|
|
3092
3206
|
return _regenerator.default.wrap(function (_context55) {
|
|
3093
3207
|
while (1) switch (_context55.prev = _context55.next) {
|
|
3094
3208
|
case 0:
|
|
@@ -3101,7 +3215,7 @@ describe('Supplementary Services tests', function () {
|
|
|
3101
3215
|
}, _callee55);
|
|
3102
3216
|
}));
|
|
3103
3217
|
return function (_x5) {
|
|
3104
|
-
return
|
|
3218
|
+
return _ref64.apply(this, arguments);
|
|
3105
3219
|
};
|
|
3106
3220
|
}());
|
|
3107
3221
|
jest.runAllTimers();
|
|
@@ -3155,7 +3269,7 @@ describe('Supplementary Services tests', function () {
|
|
|
3155
3269
|
warnSpy = jest.spyOn(_Logger.default, 'warn');
|
|
3156
3270
|
call['held'] = true;
|
|
3157
3271
|
call.on(_types2.CALL_EVENT_KEYS.RESUMED, /*#__PURE__*/function () {
|
|
3158
|
-
var
|
|
3272
|
+
var _ref66 = (0, _asyncToGenerator2.default)(/*#__PURE__*/_regenerator.default.mark(function _callee57(correlationId) {
|
|
3159
3273
|
return _regenerator.default.wrap(function (_context57) {
|
|
3160
3274
|
while (1) switch (_context57.prev = _context57.next) {
|
|
3161
3275
|
case 0:
|
|
@@ -3167,7 +3281,7 @@ describe('Supplementary Services tests', function () {
|
|
|
3167
3281
|
}, _callee57);
|
|
3168
3282
|
}));
|
|
3169
3283
|
return function (_x6) {
|
|
3170
|
-
return
|
|
3284
|
+
return _ref66.apply(this, arguments);
|
|
3171
3285
|
};
|
|
3172
3286
|
}());
|
|
3173
3287
|
_context58.next = 1;
|
|
@@ -3228,7 +3342,7 @@ describe('Supplementary Services tests', function () {
|
|
|
3228
3342
|
warnSpy = jest.spyOn(_Logger.default, 'warn');
|
|
3229
3343
|
call['held'] = true;
|
|
3230
3344
|
call.on(_types2.CALL_EVENT_KEYS.RESUMED, /*#__PURE__*/function () {
|
|
3231
|
-
var
|
|
3345
|
+
var _ref68 = (0, _asyncToGenerator2.default)(/*#__PURE__*/_regenerator.default.mark(function _callee59(correlationId) {
|
|
3232
3346
|
return _regenerator.default.wrap(function (_context59) {
|
|
3233
3347
|
while (1) switch (_context59.prev = _context59.next) {
|
|
3234
3348
|
case 0:
|
|
@@ -3240,7 +3354,7 @@ describe('Supplementary Services tests', function () {
|
|
|
3240
3354
|
}, _callee59);
|
|
3241
3355
|
}));
|
|
3242
3356
|
return function (_x7) {
|
|
3243
|
-
return
|
|
3357
|
+
return _ref68.apply(this, arguments);
|
|
3244
3358
|
};
|
|
3245
3359
|
}());
|
|
3246
3360
|
call.doHoldResume();
|
|
@@ -3299,7 +3413,7 @@ describe('Supplementary Services tests', function () {
|
|
|
3299
3413
|
jest.spyOn(webex, 'request').mockRejectedValue(responsePayload);
|
|
3300
3414
|
call['held'] = true;
|
|
3301
3415
|
call.on(_types2.CALL_EVENT_KEYS.RESUME_ERROR, /*#__PURE__*/function () {
|
|
3302
|
-
var
|
|
3416
|
+
var _ref70 = (0, _asyncToGenerator2.default)(/*#__PURE__*/_regenerator.default.mark(function _callee61(errObj) {
|
|
3303
3417
|
return _regenerator.default.wrap(function (_context61) {
|
|
3304
3418
|
while (1) switch (_context61.prev = _context61.next) {
|
|
3305
3419
|
case 0:
|
|
@@ -3312,7 +3426,7 @@ describe('Supplementary Services tests', function () {
|
|
|
3312
3426
|
}, _callee61);
|
|
3313
3427
|
}));
|
|
3314
3428
|
return function (_x8) {
|
|
3315
|
-
return
|
|
3429
|
+
return _ref70.apply(this, arguments);
|
|
3316
3430
|
};
|
|
3317
3431
|
}());
|
|
3318
3432
|
_context62.next = 1;
|
|
@@ -3350,7 +3464,7 @@ describe('Supplementary Services tests', function () {
|
|
|
3350
3464
|
jest.spyOn(webex, 'request').mockResolvedValueOnce(responsePayload).mockRejectedValueOnce(rejectPayload);
|
|
3351
3465
|
call['held'] = true;
|
|
3352
3466
|
call.on(_types2.CALL_EVENT_KEYS.RESUME_ERROR, /*#__PURE__*/function () {
|
|
3353
|
-
var
|
|
3467
|
+
var _ref72 = (0, _asyncToGenerator2.default)(/*#__PURE__*/_regenerator.default.mark(function _callee63(errObj) {
|
|
3354
3468
|
return _regenerator.default.wrap(function (_context63) {
|
|
3355
3469
|
while (1) switch (_context63.prev = _context63.next) {
|
|
3356
3470
|
case 0:
|
|
@@ -3363,7 +3477,7 @@ describe('Supplementary Services tests', function () {
|
|
|
3363
3477
|
}, _callee63);
|
|
3364
3478
|
}));
|
|
3365
3479
|
return function (_x9) {
|
|
3366
|
-
return
|
|
3480
|
+
return _ref72.apply(this, arguments);
|
|
3367
3481
|
};
|
|
3368
3482
|
}());
|
|
3369
3483
|
call.doHoldResume();
|
|
@@ -3403,7 +3517,7 @@ describe('Supplementary Services tests', function () {
|
|
|
3403
3517
|
jest.spyOn(webex, 'request').mockResolvedValue(responsePayload);
|
|
3404
3518
|
call['held'] = true;
|
|
3405
3519
|
call.on(_types2.CALL_EVENT_KEYS.RESUME_ERROR, /*#__PURE__*/function () {
|
|
3406
|
-
var
|
|
3520
|
+
var _ref74 = (0, _asyncToGenerator2.default)(/*#__PURE__*/_regenerator.default.mark(function _callee65(errObj) {
|
|
3407
3521
|
return _regenerator.default.wrap(function (_context65) {
|
|
3408
3522
|
while (1) switch (_context65.prev = _context65.next) {
|
|
3409
3523
|
case 0:
|
|
@@ -3416,7 +3530,7 @@ describe('Supplementary Services tests', function () {
|
|
|
3416
3530
|
}, _callee65);
|
|
3417
3531
|
}));
|
|
3418
3532
|
return function (_x0) {
|
|
3419
|
-
return
|
|
3533
|
+
return _ref74.apply(this, arguments);
|
|
3420
3534
|
};
|
|
3421
3535
|
}());
|
|
3422
3536
|
call.doHoldResume();
|
|
@@ -3497,7 +3611,7 @@ describe('Supplementary Services tests', function () {
|
|
|
3497
3611
|
infoSpy = jest.spyOn(_Logger.default, 'info');
|
|
3498
3612
|
metricSpy = jest.spyOn(call['metricManager'], 'submitCallMetric');
|
|
3499
3613
|
call.on(_types2.CALL_EVENT_KEYS.DISCONNECT, /*#__PURE__*/function () {
|
|
3500
|
-
var
|
|
3614
|
+
var _ref76 = (0, _asyncToGenerator2.default)(/*#__PURE__*/_regenerator.default.mark(function _callee67(correlationId) {
|
|
3501
3615
|
return _regenerator.default.wrap(function (_context67) {
|
|
3502
3616
|
while (1) switch (_context67.prev = _context67.next) {
|
|
3503
3617
|
case 0:
|
|
@@ -3509,11 +3623,11 @@ describe('Supplementary Services tests', function () {
|
|
|
3509
3623
|
}, _callee67);
|
|
3510
3624
|
}));
|
|
3511
3625
|
return function (_x1) {
|
|
3512
|
-
return
|
|
3626
|
+
return _ref76.apply(this, arguments);
|
|
3513
3627
|
};
|
|
3514
3628
|
}());
|
|
3515
3629
|
secondCall.on(_types2.CALL_EVENT_KEYS.DISCONNECT, /*#__PURE__*/function () {
|
|
3516
|
-
var
|
|
3630
|
+
var _ref77 = (0, _asyncToGenerator2.default)(/*#__PURE__*/_regenerator.default.mark(function _callee68(correlationId) {
|
|
3517
3631
|
return _regenerator.default.wrap(function (_context68) {
|
|
3518
3632
|
while (1) switch (_context68.prev = _context68.next) {
|
|
3519
3633
|
case 0:
|
|
@@ -3525,7 +3639,7 @@ describe('Supplementary Services tests', function () {
|
|
|
3525
3639
|
}, _callee68);
|
|
3526
3640
|
}));
|
|
3527
3641
|
return function (_x10) {
|
|
3528
|
-
return
|
|
3642
|
+
return _ref77.apply(this, arguments);
|
|
3529
3643
|
};
|
|
3530
3644
|
}());
|
|
3531
3645
|
_context69.next = 1;
|
|
@@ -3573,7 +3687,7 @@ describe('Supplementary Services tests', function () {
|
|
|
3573
3687
|
infoSpy = jest.spyOn(_Logger.default, 'info');
|
|
3574
3688
|
metricSpy = jest.spyOn(call['metricManager'], 'submitCallMetric');
|
|
3575
3689
|
call.on(_types2.CALL_EVENT_KEYS.DISCONNECT, /*#__PURE__*/function () {
|
|
3576
|
-
var
|
|
3690
|
+
var _ref79 = (0, _asyncToGenerator2.default)(/*#__PURE__*/_regenerator.default.mark(function _callee70(correlationId) {
|
|
3577
3691
|
return _regenerator.default.wrap(function (_context70) {
|
|
3578
3692
|
while (1) switch (_context70.prev = _context70.next) {
|
|
3579
3693
|
case 0:
|
|
@@ -3585,7 +3699,7 @@ describe('Supplementary Services tests', function () {
|
|
|
3585
3699
|
}, _callee70);
|
|
3586
3700
|
}));
|
|
3587
3701
|
return function (_x11) {
|
|
3588
|
-
return
|
|
3702
|
+
return _ref79.apply(this, arguments);
|
|
3589
3703
|
};
|
|
3590
3704
|
}());
|
|
3591
3705
|
_context71.next = 1;
|