@webex/plugin-meetings 3.0.0-beta.317 → 3.0.0-beta.318
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/breakouts/index.js
CHANGED
|
@@ -1041,7 +1041,7 @@ var Breakouts = _webexCore.WebexPlugin.extend({
|
|
|
1041
1041
|
this.trigger(_constants.BREAKOUTS.EVENTS.ASK_RETURN_TO_MAIN);
|
|
1042
1042
|
}
|
|
1043
1043
|
},
|
|
1044
|
-
version: "3.0.0-beta.
|
|
1044
|
+
version: "3.0.0-beta.318"
|
|
1045
1045
|
});
|
|
1046
1046
|
var _default = Breakouts;
|
|
1047
1047
|
exports.default = _default;
|
package/dist/webinar/index.js
CHANGED
|
@@ -62,7 +62,7 @@ var Webinar = _webexCore.WebexPlugin.extend({
|
|
|
62
62
|
updateCanManageWebcast: function updateCanManageWebcast(canManageWebcast) {
|
|
63
63
|
this.set('canManageWebcast', canManageWebcast);
|
|
64
64
|
},
|
|
65
|
-
version: "3.0.0-beta.
|
|
65
|
+
version: "3.0.0-beta.318"
|
|
66
66
|
});
|
|
67
67
|
var _default = Webinar;
|
|
68
68
|
exports.default = _default;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@webex/plugin-meetings",
|
|
3
|
-
"version": "3.0.0-beta.
|
|
3
|
+
"version": "3.0.0-beta.318",
|
|
4
4
|
"description": "",
|
|
5
5
|
"license": "Cisco EULA (https://www.cisco.com/c/en/us/products/end-user-license-agreement.html)",
|
|
6
6
|
"contributors": [
|
|
@@ -32,12 +32,13 @@
|
|
|
32
32
|
"build": "yarn run -T tsc --declaration true --declarationDir ./dist/types"
|
|
33
33
|
},
|
|
34
34
|
"devDependencies": {
|
|
35
|
-
"@
|
|
36
|
-
"@webex/
|
|
37
|
-
"@webex/test-helper-
|
|
38
|
-
"@webex/test-helper-
|
|
39
|
-
"@webex/test-helper-
|
|
40
|
-
"@webex/test-helper-
|
|
35
|
+
"@peculiar/webcrypto": "^1.4.3",
|
|
36
|
+
"@webex/plugin-meetings": "3.0.0-beta.318",
|
|
37
|
+
"@webex/test-helper-chai": "3.0.0-beta.318",
|
|
38
|
+
"@webex/test-helper-mocha": "3.0.0-beta.318",
|
|
39
|
+
"@webex/test-helper-mock-webex": "3.0.0-beta.318",
|
|
40
|
+
"@webex/test-helper-retry": "3.0.0-beta.318",
|
|
41
|
+
"@webex/test-helper-test-users": "3.0.0-beta.318",
|
|
41
42
|
"chai": "^4.3.4",
|
|
42
43
|
"chai-as-promised": "^7.1.1",
|
|
43
44
|
"jsdom-global": "3.0.2",
|
|
@@ -46,19 +47,19 @@
|
|
|
46
47
|
"typescript": "^4.7.4"
|
|
47
48
|
},
|
|
48
49
|
"dependencies": {
|
|
49
|
-
"@webex/common": "3.0.0-beta.
|
|
50
|
-
"@webex/internal-media-core": "2.2.
|
|
51
|
-
"@webex/internal-plugin-conversation": "3.0.0-beta.
|
|
52
|
-
"@webex/internal-plugin-device": "3.0.0-beta.
|
|
53
|
-
"@webex/internal-plugin-llm": "3.0.0-beta.
|
|
54
|
-
"@webex/internal-plugin-mercury": "3.0.0-beta.
|
|
55
|
-
"@webex/internal-plugin-metrics": "3.0.0-beta.
|
|
56
|
-
"@webex/internal-plugin-support": "3.0.0-beta.
|
|
57
|
-
"@webex/internal-plugin-user": "3.0.0-beta.
|
|
58
|
-
"@webex/media-helpers": "3.0.0-beta.
|
|
59
|
-
"@webex/plugin-people": "3.0.0-beta.
|
|
60
|
-
"@webex/plugin-rooms": "3.0.0-beta.
|
|
61
|
-
"@webex/webex-core": "3.0.0-beta.
|
|
50
|
+
"@webex/common": "3.0.0-beta.318",
|
|
51
|
+
"@webex/internal-media-core": "2.2.2",
|
|
52
|
+
"@webex/internal-plugin-conversation": "3.0.0-beta.318",
|
|
53
|
+
"@webex/internal-plugin-device": "3.0.0-beta.318",
|
|
54
|
+
"@webex/internal-plugin-llm": "3.0.0-beta.318",
|
|
55
|
+
"@webex/internal-plugin-mercury": "3.0.0-beta.318",
|
|
56
|
+
"@webex/internal-plugin-metrics": "3.0.0-beta.318",
|
|
57
|
+
"@webex/internal-plugin-support": "3.0.0-beta.318",
|
|
58
|
+
"@webex/internal-plugin-user": "3.0.0-beta.318",
|
|
59
|
+
"@webex/media-helpers": "3.0.0-beta.318",
|
|
60
|
+
"@webex/plugin-people": "3.0.0-beta.318",
|
|
61
|
+
"@webex/plugin-rooms": "3.0.0-beta.318",
|
|
62
|
+
"@webex/webex-core": "3.0.0-beta.318",
|
|
62
63
|
"ampersand-collection": "^2.0.2",
|
|
63
64
|
"bowser": "^2.11.0",
|
|
64
65
|
"btoa": "^1.2.1",
|
|
@@ -3,6 +3,10 @@
|
|
|
3
3
|
*/
|
|
4
4
|
import 'jsdom-global/register';
|
|
5
5
|
|
|
6
|
+
// Polyfill for crypto: https://github.com/jsdom/jsdom/issues/1612#issuecomment-663210638
|
|
7
|
+
import {Crypto} from '@peculiar/webcrypto';
|
|
8
|
+
global.crypto = new Crypto();
|
|
9
|
+
|
|
6
10
|
import Device from '@webex/internal-plugin-device';
|
|
7
11
|
import Mercury from '@webex/internal-plugin-mercury';
|
|
8
12
|
import {assert} from '@webex/test-helper-chai';
|
|
@@ -32,10 +36,10 @@ import {
|
|
|
32
36
|
EVENT_TRIGGERS,
|
|
33
37
|
} from '../../../../src/constants';
|
|
34
38
|
import CaptchaError from '@webex/plugin-meetings/src/common/errors/captcha-error';
|
|
35
|
-
import {
|
|
39
|
+
import {forEach} from 'lodash';
|
|
36
40
|
import PasswordError from '@webex/plugin-meetings/src/common/errors/password-error';
|
|
37
41
|
import PermissionError from '@webex/plugin-meetings/src/common/errors/permission';
|
|
38
|
-
import {NoiseReductionEffect,VirtualBackgroundEffect} from '@webex/media-helpers';
|
|
42
|
+
import {NoiseReductionEffect, VirtualBackgroundEffect} from '@webex/media-helpers';
|
|
39
43
|
import NoMeetingInfoError from '../../../../src/common/errors/no-meeting-info';
|
|
40
44
|
|
|
41
45
|
describe('plugin-meetings', () => {
|
|
@@ -75,7 +79,7 @@ describe('plugin-meetings', () => {
|
|
|
75
79
|
describe('meetings index', () => {
|
|
76
80
|
beforeEach(() => {
|
|
77
81
|
MeetingsUtil.checkH264Support = sinon.stub();
|
|
78
|
-
|
|
82
|
+
uuid1 = uuid.v4();
|
|
79
83
|
url1 = `https://example.com/${uuid.v4()}`;
|
|
80
84
|
uri1 = `test-${uuid.v4()}@example.com`;
|
|
81
85
|
test1 = `test-${uuid.v4()}`;
|
|
@@ -333,10 +337,10 @@ describe('plugin-meetings', () => {
|
|
|
333
337
|
beforeEach(() => {
|
|
334
338
|
webex.credentials = {
|
|
335
339
|
supertoken: {
|
|
336
|
-
access_token:
|
|
337
|
-
}
|
|
340
|
+
access_token: 'fake_token',
|
|
341
|
+
},
|
|
338
342
|
};
|
|
339
|
-
})
|
|
343
|
+
});
|
|
340
344
|
|
|
341
345
|
it('creates background effect', async () => {
|
|
342
346
|
const result = await webex.meetings.createVirtualBackgroundEffect();
|
|
@@ -350,7 +354,7 @@ describe('plugin-meetings', () => {
|
|
|
350
354
|
generator: 'worker',
|
|
351
355
|
quality: 'LOW',
|
|
352
356
|
authToken: 'fake_token',
|
|
353
|
-
mirror: false
|
|
357
|
+
mirror: false,
|
|
354
358
|
});
|
|
355
359
|
assert.exists(result.enable);
|
|
356
360
|
assert.exists(result.disable);
|
|
@@ -359,13 +363,13 @@ describe('plugin-meetings', () => {
|
|
|
359
363
|
|
|
360
364
|
it('creates background effect with custom options passed', async () => {
|
|
361
365
|
const effectOptions = {
|
|
362
|
-
generator:
|
|
366
|
+
generator: 'local',
|
|
363
367
|
frameRate: 45,
|
|
364
|
-
mode:
|
|
368
|
+
mode: 'IMAGE',
|
|
365
369
|
mirror: false,
|
|
366
|
-
quality:
|
|
367
|
-
blurStrength:
|
|
368
|
-
bgImageUrl:
|
|
370
|
+
quality: 'HIGH',
|
|
371
|
+
blurStrength: 'STRONG',
|
|
372
|
+
bgImageUrl: 'https://test.webex.com/landscape.5a535788.jpg',
|
|
369
373
|
};
|
|
370
374
|
|
|
371
375
|
const result = await webex.meetings.createVirtualBackgroundEffect(effectOptions);
|
|
@@ -373,21 +377,21 @@ describe('plugin-meetings', () => {
|
|
|
373
377
|
assert.exists(result);
|
|
374
378
|
assert.instanceOf(result, VirtualBackgroundEffect);
|
|
375
379
|
assert.containsAllKeys(result, ['loadModel', 'isEnabled', 'options']);
|
|
376
|
-
assert.deepEqual(result.options, {...effectOptions, authToken:
|
|
380
|
+
assert.deepEqual(result.options, {...effectOptions, authToken: 'fake_token'});
|
|
377
381
|
assert.exists(result.enable);
|
|
378
382
|
assert.exists(result.disable);
|
|
379
383
|
assert.exists(result.dispose);
|
|
380
384
|
});
|
|
381
|
-
})
|
|
385
|
+
});
|
|
382
386
|
|
|
383
387
|
describe('noise reduction effect', () => {
|
|
384
388
|
beforeEach(() => {
|
|
385
389
|
webex.credentials = {
|
|
386
390
|
supertoken: {
|
|
387
|
-
access_token:
|
|
388
|
-
}
|
|
391
|
+
access_token: 'fake_token',
|
|
392
|
+
},
|
|
389
393
|
};
|
|
390
|
-
})
|
|
394
|
+
});
|
|
391
395
|
|
|
392
396
|
it('creates noise reduction effect', async () => {
|
|
393
397
|
const result = await webex.meetings.createNoiseReductionEffect({audioContext: {}});
|
|
@@ -397,7 +401,7 @@ describe('plugin-meetings', () => {
|
|
|
397
401
|
assert.containsAllKeys(result, ['audioContext', 'isEnabled', 'isReady', 'options']);
|
|
398
402
|
assert.deepEqual(result.options, {
|
|
399
403
|
authToken: 'fake_token',
|
|
400
|
-
audioContext: {}
|
|
404
|
+
audioContext: {},
|
|
401
405
|
});
|
|
402
406
|
assert.exists(result.enable);
|
|
403
407
|
assert.exists(result.disable);
|
|
@@ -407,8 +411,8 @@ describe('plugin-meetings', () => {
|
|
|
407
411
|
it('creates noise reduction effect with custom options passed', async () => {
|
|
408
412
|
const effectOptions = {
|
|
409
413
|
audioContext: {},
|
|
410
|
-
mode:
|
|
411
|
-
env:
|
|
414
|
+
mode: 'WORKLET',
|
|
415
|
+
env: 'prod',
|
|
412
416
|
};
|
|
413
417
|
|
|
414
418
|
const result = await webex.meetings.createNoiseReductionEffect(effectOptions);
|
|
@@ -416,12 +420,12 @@ describe('plugin-meetings', () => {
|
|
|
416
420
|
assert.exists(result);
|
|
417
421
|
assert.instanceOf(result, NoiseReductionEffect);
|
|
418
422
|
assert.containsAllKeys(result, ['audioContext', 'isEnabled', 'isReady', 'options']);
|
|
419
|
-
assert.deepEqual(result.options, {...effectOptions, authToken:
|
|
423
|
+
assert.deepEqual(result.options, {...effectOptions, authToken: 'fake_token'});
|
|
420
424
|
assert.exists(result.enable);
|
|
421
425
|
assert.exists(result.disable);
|
|
422
426
|
assert.exists(result.dispose);
|
|
423
427
|
});
|
|
424
|
-
})
|
|
428
|
+
});
|
|
425
429
|
|
|
426
430
|
describe('gets', () => {
|
|
427
431
|
describe('#getReachability', () => {
|
|
@@ -431,10 +435,7 @@ describe('plugin-meetings', () => {
|
|
|
431
435
|
it('gets the reachability data instance from webex.meetings', () => {
|
|
432
436
|
const reachability = webex.meetings.getReachability();
|
|
433
437
|
|
|
434
|
-
assert.exists(
|
|
435
|
-
reachability,
|
|
436
|
-
'reachability is defined'
|
|
437
|
-
);
|
|
438
|
+
assert.exists(reachability, 'reachability is defined');
|
|
438
439
|
assert.instanceOf(reachability, Reachability, 'should be a reachability instance');
|
|
439
440
|
});
|
|
440
441
|
});
|
|
@@ -510,7 +511,6 @@ describe('plugin-meetings', () => {
|
|
|
510
511
|
);
|
|
511
512
|
});
|
|
512
513
|
describe('when meeting is returned', () => {
|
|
513
|
-
|
|
514
514
|
beforeEach(() => {
|
|
515
515
|
webex.meetings.meetingCollection.getByKey = sinon.stub().returns({
|
|
516
516
|
locusInfo,
|
|
@@ -645,31 +645,56 @@ describe('plugin-meetings', () => {
|
|
|
645
645
|
await create;
|
|
646
646
|
assert.calledOnce(webex.meetings.createMeeting);
|
|
647
647
|
assert.calledWith(webex.meetings.createMeeting, ...createMeetingParameters);
|
|
648
|
-
}
|
|
648
|
+
};
|
|
649
649
|
|
|
650
650
|
it('calls createMeeting and returns its promise', async () => {
|
|
651
|
-
checkCallCreateMeeting(
|
|
651
|
+
checkCallCreateMeeting(
|
|
652
|
+
[test1, test2, FAKE_USE_RANDOM_DELAY, {}, correlationId, true],
|
|
653
|
+
[test1, test2, FAKE_USE_RANDOM_DELAY, {}, correlationId, true]
|
|
654
|
+
);
|
|
652
655
|
});
|
|
653
656
|
|
|
654
657
|
it('calls createMeeting when failOnMissingMeetinginfo is undefined and returns its promise', async () => {
|
|
655
|
-
checkCallCreateMeeting(
|
|
658
|
+
checkCallCreateMeeting(
|
|
659
|
+
[test1, test2, FAKE_USE_RANDOM_DELAY, {}, correlationId, undefined],
|
|
660
|
+
[test1, test2, FAKE_USE_RANDOM_DELAY, {}, correlationId, false]
|
|
661
|
+
);
|
|
656
662
|
});
|
|
657
663
|
|
|
658
664
|
it('calls createMeeting when failOnMissingMeetinginfo is false and returns its promise', async () => {
|
|
659
|
-
checkCallCreateMeeting(
|
|
665
|
+
checkCallCreateMeeting(
|
|
666
|
+
[test1, test2, FAKE_USE_RANDOM_DELAY, {}, correlationId, false],
|
|
667
|
+
[test1, test2, FAKE_USE_RANDOM_DELAY, {}, correlationId, false]
|
|
668
|
+
);
|
|
660
669
|
});
|
|
661
670
|
|
|
662
671
|
it('calls createMeeting with extra info params and returns its promise', async () => {
|
|
663
672
|
const FAKE_USE_RANDOM_DELAY = false;
|
|
664
673
|
const correlationId = 'my-correlationId';
|
|
665
674
|
|
|
666
|
-
const FAKE_INFO_EXTRA_PARAMS = {
|
|
667
|
-
|
|
675
|
+
const FAKE_INFO_EXTRA_PARAMS = {
|
|
676
|
+
mtid: 'm9fe0afd8c435e892afcce9ea25b97046',
|
|
677
|
+
joinTXId: 'TSmrX61wNF',
|
|
678
|
+
};
|
|
679
|
+
const create = webex.meetings.create(
|
|
680
|
+
test1,
|
|
681
|
+
test2,
|
|
682
|
+
FAKE_USE_RANDOM_DELAY,
|
|
683
|
+
FAKE_INFO_EXTRA_PARAMS,
|
|
684
|
+
correlationId
|
|
685
|
+
);
|
|
668
686
|
|
|
669
687
|
assert.exists(create.then);
|
|
670
688
|
await create;
|
|
671
689
|
assert.calledOnce(webex.meetings.createMeeting);
|
|
672
|
-
assert.calledWith(
|
|
690
|
+
assert.calledWith(
|
|
691
|
+
webex.meetings.createMeeting,
|
|
692
|
+
test1,
|
|
693
|
+
test2,
|
|
694
|
+
FAKE_USE_RANDOM_DELAY,
|
|
695
|
+
FAKE_INFO_EXTRA_PARAMS,
|
|
696
|
+
correlationId
|
|
697
|
+
);
|
|
673
698
|
});
|
|
674
699
|
|
|
675
700
|
it('creates a new meeting when a scheduled meeting exists in the conversation', async () => {
|
|
@@ -765,7 +790,6 @@ describe('plugin-meetings', () => {
|
|
|
765
790
|
});
|
|
766
791
|
describe('#handleLocusEvent', () => {
|
|
767
792
|
describe('there was a meeting', () => {
|
|
768
|
-
|
|
769
793
|
beforeEach(() => {
|
|
770
794
|
webex.meetings.meetingCollection.getByKey = sinon.stub().returns({
|
|
771
795
|
locusInfo,
|
|
@@ -831,7 +855,7 @@ describe('plugin-meetings', () => {
|
|
|
831
855
|
},
|
|
832
856
|
},
|
|
833
857
|
info: {
|
|
834
|
-
webExMeetingId
|
|
858
|
+
webExMeetingId,
|
|
835
859
|
},
|
|
836
860
|
},
|
|
837
861
|
eventType: 'locus.difference',
|
|
@@ -839,7 +863,11 @@ describe('plugin-meetings', () => {
|
|
|
839
863
|
});
|
|
840
864
|
assert.callCount(webex.meetings.meetingCollection.getByKey, 6);
|
|
841
865
|
assert.calledWith(webex.meetings.meetingCollection.getByKey, 'locusUrl', url1);
|
|
842
|
-
assert.calledWith(
|
|
866
|
+
assert.calledWith(
|
|
867
|
+
webex.meetings.meetingCollection.getByKey,
|
|
868
|
+
'meetingNumber',
|
|
869
|
+
webExMeetingId
|
|
870
|
+
);
|
|
843
871
|
assert.calledOnce(initialSetup);
|
|
844
872
|
assert.calledWith(initialSetup, {
|
|
845
873
|
id: uuid1,
|
|
@@ -854,7 +882,7 @@ describe('plugin-meetings', () => {
|
|
|
854
882
|
},
|
|
855
883
|
},
|
|
856
884
|
info: {
|
|
857
|
-
webExMeetingId
|
|
885
|
+
webExMeetingId,
|
|
858
886
|
},
|
|
859
887
|
});
|
|
860
888
|
});
|
|
@@ -868,7 +896,7 @@ describe('plugin-meetings', () => {
|
|
|
868
896
|
},
|
|
869
897
|
},
|
|
870
898
|
info: {
|
|
871
|
-
webExMeetingId
|
|
899
|
+
webExMeetingId,
|
|
872
900
|
},
|
|
873
901
|
},
|
|
874
902
|
eventType: 'locus.difference',
|
|
@@ -876,7 +904,11 @@ describe('plugin-meetings', () => {
|
|
|
876
904
|
});
|
|
877
905
|
assert.callCount(webex.meetings.meetingCollection.getByKey, 5);
|
|
878
906
|
assert.calledWith(webex.meetings.meetingCollection.getByKey, 'locusUrl', url1);
|
|
879
|
-
assert.calledWith(
|
|
907
|
+
assert.calledWith(
|
|
908
|
+
webex.meetings.meetingCollection.getByKey,
|
|
909
|
+
'meetingNumber',
|
|
910
|
+
webExMeetingId
|
|
911
|
+
);
|
|
880
912
|
assert.calledOnce(initialSetup);
|
|
881
913
|
assert.calledWith(initialSetup, {
|
|
882
914
|
id: uuid1,
|
|
@@ -886,7 +918,7 @@ describe('plugin-meetings', () => {
|
|
|
886
918
|
},
|
|
887
919
|
},
|
|
888
920
|
info: {
|
|
889
|
-
webExMeetingId
|
|
921
|
+
webExMeetingId,
|
|
890
922
|
},
|
|
891
923
|
});
|
|
892
924
|
});
|
|
@@ -933,7 +965,7 @@ describe('plugin-meetings', () => {
|
|
|
933
965
|
},
|
|
934
966
|
},
|
|
935
967
|
info: {
|
|
936
|
-
webExMeetingId
|
|
968
|
+
webExMeetingId,
|
|
937
969
|
},
|
|
938
970
|
},
|
|
939
971
|
eventType: test1,
|
|
@@ -941,7 +973,11 @@ describe('plugin-meetings', () => {
|
|
|
941
973
|
});
|
|
942
974
|
assert.callCount(webex.meetings.meetingCollection.getByKey, 5);
|
|
943
975
|
assert.calledWith(webex.meetings.meetingCollection.getByKey, 'locusUrl', url1);
|
|
944
|
-
assert.calledWith(
|
|
976
|
+
assert.calledWith(
|
|
977
|
+
webex.meetings.meetingCollection.getByKey,
|
|
978
|
+
'meetingNumber',
|
|
979
|
+
webExMeetingId
|
|
980
|
+
);
|
|
945
981
|
assert.calledOnce(initialSetup);
|
|
946
982
|
assert.calledWith(initialSetup, {
|
|
947
983
|
id: uuid1,
|
|
@@ -951,7 +987,7 @@ describe('plugin-meetings', () => {
|
|
|
951
987
|
},
|
|
952
988
|
},
|
|
953
989
|
info: {
|
|
954
|
-
webExMeetingId
|
|
990
|
+
webExMeetingId,
|
|
955
991
|
},
|
|
956
992
|
});
|
|
957
993
|
});
|
|
@@ -1023,7 +1059,10 @@ describe('plugin-meetings', () => {
|
|
|
1023
1059
|
});
|
|
1024
1060
|
describe('successful MeetingInfo.#fetchMeetingInfo', () => {
|
|
1025
1061
|
let clock, setTimeoutSpy, fakeMeetingStartTimeString, FAKE_TIME_TO_START;
|
|
1026
|
-
const FAKE_INFO_EXTRA_PARAMS = {
|
|
1062
|
+
const FAKE_INFO_EXTRA_PARAMS = {
|
|
1063
|
+
mtid: 'm9fe0afd8c435e892afcce9ea25b97046',
|
|
1064
|
+
joinTXId: 'TSmrX61wNF',
|
|
1065
|
+
};
|
|
1027
1066
|
|
|
1028
1067
|
beforeEach(() => {
|
|
1029
1068
|
clock = sinon.useFakeTimers();
|
|
@@ -1055,13 +1094,23 @@ describe('plugin-meetings', () => {
|
|
|
1055
1094
|
type,
|
|
1056
1095
|
extraParams = {},
|
|
1057
1096
|
expectedMeetingData = {},
|
|
1058
|
-
sendCAevents = false
|
|
1097
|
+
sendCAevents = false
|
|
1059
1098
|
) => {
|
|
1060
1099
|
assert.calledOnce(webex.meetings.meetingInfo.fetchMeetingInfo);
|
|
1061
1100
|
assert.calledOnce(MeetingsUtil.getMeetingAddedType);
|
|
1062
1101
|
assert.notCalled(setTimeoutSpy);
|
|
1063
1102
|
assert.callCount(TriggerProxy.trigger, 5);
|
|
1064
|
-
assert.calledWith(
|
|
1103
|
+
assert.calledWith(
|
|
1104
|
+
webex.meetings.meetingInfo.fetchMeetingInfo,
|
|
1105
|
+
destination,
|
|
1106
|
+
type,
|
|
1107
|
+
null,
|
|
1108
|
+
null,
|
|
1109
|
+
undefined,
|
|
1110
|
+
undefined,
|
|
1111
|
+
extraParams,
|
|
1112
|
+
{meetingId: meeting.id, sendCAevents}
|
|
1113
|
+
);
|
|
1065
1114
|
assert.calledWith(MeetingsUtil.getMeetingAddedType, 'test type');
|
|
1066
1115
|
|
|
1067
1116
|
if (expectedMeetingData.permissionToken) {
|
|
@@ -1070,7 +1119,7 @@ describe('plugin-meetings', () => {
|
|
|
1070
1119
|
if (expectedMeetingData.meetingJoinUrl) {
|
|
1071
1120
|
assert.equal(meeting.meetingJoinUrl, expectedMeetingData.meetingJoinUrl);
|
|
1072
1121
|
}
|
|
1073
|
-
if(expectedMeetingData.correlationId) {
|
|
1122
|
+
if (expectedMeetingData.correlationId) {
|
|
1074
1123
|
assert.equal(meeting.correlationId, expectedMeetingData.correlationId);
|
|
1075
1124
|
}
|
|
1076
1125
|
assert.equal(meeting.destination, destination);
|
|
@@ -1105,14 +1154,27 @@ describe('plugin-meetings', () => {
|
|
|
1105
1154
|
correlationId: meeting.id,
|
|
1106
1155
|
};
|
|
1107
1156
|
|
|
1108
|
-
checkCreateWithoutDelay(
|
|
1157
|
+
checkCreateWithoutDelay(
|
|
1158
|
+
meeting,
|
|
1159
|
+
'test destination',
|
|
1160
|
+
'test type',
|
|
1161
|
+
{},
|
|
1162
|
+
expectedMeetingData
|
|
1163
|
+
);
|
|
1109
1164
|
});
|
|
1110
1165
|
|
|
1111
1166
|
[undefined, FAKE_INFO_EXTRA_PARAMS].forEach((infoExtraParams) => {
|
|
1112
1167
|
const infoExtraParamsProvided = infoExtraParams !== undefined;
|
|
1113
1168
|
|
|
1114
|
-
it(`creates the meeting from a successful meeting info fetch meeting resolve testing${
|
|
1115
|
-
|
|
1169
|
+
it(`creates the meeting from a successful meeting info fetch meeting resolve testing${
|
|
1170
|
+
infoExtraParamsProvided ? ' with infoExtraParams' : ''
|
|
1171
|
+
}`, async () => {
|
|
1172
|
+
const meeting = await webex.meetings.createMeeting(
|
|
1173
|
+
'test destination',
|
|
1174
|
+
'test type',
|
|
1175
|
+
false,
|
|
1176
|
+
infoExtraParams
|
|
1177
|
+
);
|
|
1116
1178
|
const expectedMeetingData = {
|
|
1117
1179
|
permissionToken: 'PT',
|
|
1118
1180
|
meetingJoinUrl: 'meetingJoinUrl',
|
|
@@ -1123,10 +1185,18 @@ describe('plugin-meetings', () => {
|
|
|
1123
1185
|
Meeting,
|
|
1124
1186
|
'createMeeting should eventually resolve to a Meeting Object'
|
|
1125
1187
|
);
|
|
1126
|
-
checkCreateWithoutDelay(
|
|
1188
|
+
checkCreateWithoutDelay(
|
|
1189
|
+
meeting,
|
|
1190
|
+
'test destination',
|
|
1191
|
+
'test type',
|
|
1192
|
+
infoExtraParamsProvided ? infoExtraParams : {},
|
|
1193
|
+
expectedMeetingData
|
|
1194
|
+
);
|
|
1127
1195
|
});
|
|
1128
1196
|
|
|
1129
|
-
it(`creates the meeting from a successful meeting info fetch with random delay${
|
|
1197
|
+
it(`creates the meeting from a successful meeting info fetch with random delay${
|
|
1198
|
+
infoExtraParamsProvided ? ' with infoExtraParams' : ''
|
|
1199
|
+
}`, async () => {
|
|
1130
1200
|
const FAKE_LOCUS_MEETING = {
|
|
1131
1201
|
conversationUrl: 'locusConvURL',
|
|
1132
1202
|
url: 'locusUrl',
|
|
@@ -1214,7 +1284,7 @@ describe('plugin-meetings', () => {
|
|
|
1214
1284
|
'meeting:meetingInfoAvailable'
|
|
1215
1285
|
);
|
|
1216
1286
|
});
|
|
1217
|
-
})
|
|
1287
|
+
});
|
|
1218
1288
|
|
|
1219
1289
|
it('creates the meeting from a successful meeting info fetch that has no random delay because it is active', async () => {
|
|
1220
1290
|
const FAKE_LOCUS_MEETING = {
|
|
@@ -1315,14 +1385,27 @@ describe('plugin-meetings', () => {
|
|
|
1315
1385
|
});
|
|
1316
1386
|
|
|
1317
1387
|
it('creates meeting with the correlationId provided', async () => {
|
|
1318
|
-
const meeting = await webex.meetings.createMeeting(
|
|
1388
|
+
const meeting = await webex.meetings.createMeeting(
|
|
1389
|
+
'test destination',
|
|
1390
|
+
'test type',
|
|
1391
|
+
false,
|
|
1392
|
+
{},
|
|
1393
|
+
'my-correlationId'
|
|
1394
|
+
);
|
|
1319
1395
|
|
|
1320
1396
|
const expectedMeetingData = {
|
|
1321
1397
|
correlationId: 'my-correlationId',
|
|
1322
1398
|
};
|
|
1323
1399
|
|
|
1324
|
-
checkCreateWithoutDelay(
|
|
1325
|
-
|
|
1400
|
+
checkCreateWithoutDelay(
|
|
1401
|
+
meeting,
|
|
1402
|
+
'test destination',
|
|
1403
|
+
'test type',
|
|
1404
|
+
{},
|
|
1405
|
+
expectedMeetingData,
|
|
1406
|
+
true
|
|
1407
|
+
);
|
|
1408
|
+
});
|
|
1326
1409
|
});
|
|
1327
1410
|
|
|
1328
1411
|
describe('rejected MeetingInfo.#fetchMeetingInfo', () => {
|
|
@@ -1332,16 +1415,21 @@ describe('plugin-meetings', () => {
|
|
|
1332
1415
|
webex.meetings.meetingInfo.fetchMeetingInfo = sinon
|
|
1333
1416
|
.stub()
|
|
1334
1417
|
.returns(Promise.reject(new Error('test')));
|
|
1335
|
-
webex.meetings.destroy = sinon
|
|
1336
|
-
.stub()
|
|
1337
|
-
.returns(Promise.resolve());
|
|
1418
|
+
webex.meetings.destroy = sinon.stub().returns(Promise.resolve());
|
|
1338
1419
|
webex.meetings.createMeeting = sinon.spy(webex.meetings.createMeeting);
|
|
1339
1420
|
});
|
|
1340
1421
|
|
|
1341
1422
|
const checkCreateMeetingWithNoMeetingInfo = async (failOnMissingMeetingInfo, destroy) => {
|
|
1342
1423
|
try {
|
|
1343
|
-
const meeting = await webex.meetings.createMeeting(
|
|
1344
|
-
|
|
1424
|
+
const meeting = await webex.meetings.createMeeting(
|
|
1425
|
+
'test destination',
|
|
1426
|
+
'test type',
|
|
1427
|
+
undefined,
|
|
1428
|
+
undefined,
|
|
1429
|
+
undefined,
|
|
1430
|
+
failOnMissingMeetingInfo
|
|
1431
|
+
);
|
|
1432
|
+
|
|
1345
1433
|
assert.instanceOf(
|
|
1346
1434
|
meeting,
|
|
1347
1435
|
Meeting,
|
|
@@ -1355,9 +1443,13 @@ describe('plugin-meetings', () => {
|
|
|
1355
1443
|
'test destination',
|
|
1356
1444
|
'test type'
|
|
1357
1445
|
);
|
|
1358
|
-
|
|
1446
|
+
|
|
1359
1447
|
if (destroy) {
|
|
1360
|
-
assert.calledWith(
|
|
1448
|
+
assert.calledWith(
|
|
1449
|
+
webex.meetings.destroy,
|
|
1450
|
+
sinon.match.instanceOf(Meeting),
|
|
1451
|
+
'MISSING_MEETING_INFO'
|
|
1452
|
+
);
|
|
1361
1453
|
assert.notCalled(MeetingsUtil.getMeetingAddedType);
|
|
1362
1454
|
assert.notCalled(TriggerProxy.trigger);
|
|
1363
1455
|
assert.throw(webex.meetings.createMeeting, 'meeting information not found');
|
|
@@ -1378,10 +1470,10 @@ describe('plugin-meetings', () => {
|
|
|
1378
1470
|
}
|
|
1379
1471
|
);
|
|
1380
1472
|
}
|
|
1381
|
-
} catch (err) {
|
|
1473
|
+
} catch (err) {
|
|
1382
1474
|
assert.instanceOf(err, NoMeetingInfoError);
|
|
1383
1475
|
}
|
|
1384
|
-
}
|
|
1476
|
+
};
|
|
1385
1477
|
|
|
1386
1478
|
it('creates the meeting from a rejected meeting info fetch', async () => {
|
|
1387
1479
|
checkCreateMeetingWithNoMeetingInfo(false, false);
|
|
@@ -1526,7 +1618,6 @@ describe('plugin-meetings', () => {
|
|
|
1526
1618
|
});
|
|
1527
1619
|
|
|
1528
1620
|
describe('#fetchUserPreferredWebexSite', () => {
|
|
1529
|
-
|
|
1530
1621
|
let loggerProxySpy;
|
|
1531
1622
|
|
|
1532
1623
|
it('should call request.getMeetingPreferences to get the preferred webex site ', async () => {
|
|
@@ -1544,12 +1635,10 @@ describe('plugin-meetings', () => {
|
|
|
1544
1635
|
getMeetingPreferences: sinon.stub().returns(Promise.resolve({})),
|
|
1545
1636
|
},
|
|
1546
1637
|
user: {
|
|
1547
|
-
get: sinon.stub().returns(
|
|
1548
|
-
Promise.resolve(user)
|
|
1549
|
-
),
|
|
1638
|
+
get: sinon.stub().returns(Promise.resolve(user)),
|
|
1550
1639
|
},
|
|
1551
1640
|
});
|
|
1552
|
-
}
|
|
1641
|
+
};
|
|
1553
1642
|
|
|
1554
1643
|
it('should not fail if UserPreferred info is not fetched ', async () => {
|
|
1555
1644
|
setup();
|
|
@@ -1586,24 +1675,27 @@ describe('plugin-meetings', () => {
|
|
|
1586
1675
|
assert.notCalled(loggerProxySpy);
|
|
1587
1676
|
});
|
|
1588
1677
|
|
|
1589
|
-
forEach(
|
|
1590
|
-
|
|
1591
|
-
|
|
1592
|
-
|
|
1593
|
-
|
|
1594
|
-
|
|
1595
|
-
|
|
1596
|
-
|
|
1597
|
-
|
|
1598
|
-
|
|
1599
|
-
|
|
1600
|
-
|
|
1601
|
-
|
|
1602
|
-
|
|
1603
|
-
|
|
1604
|
-
|
|
1605
|
-
|
|
1606
|
-
|
|
1678
|
+
forEach(
|
|
1679
|
+
[
|
|
1680
|
+
{user: undefined},
|
|
1681
|
+
{user: {userPreferences: {}}},
|
|
1682
|
+
{user: {userPreferences: {userPreferencesItems: {}}}},
|
|
1683
|
+
{user: {userPreferences: {userPreferencesItems: {preferredWebExSite: undefined}}}},
|
|
1684
|
+
],
|
|
1685
|
+
({user}) => {
|
|
1686
|
+
it(`should handle invalid user data ${user}`, async () => {
|
|
1687
|
+
setup({user});
|
|
1688
|
+
|
|
1689
|
+
await webex.meetings.fetchUserPreferredWebexSite();
|
|
1690
|
+
|
|
1691
|
+
assert.equal(webex.meetings.preferredWebexSite, '');
|
|
1692
|
+
assert.calledOnceWithExactly(
|
|
1693
|
+
loggerProxySpy,
|
|
1694
|
+
'Failed to fetch preferred site from user - no site will be set'
|
|
1695
|
+
);
|
|
1696
|
+
});
|
|
1697
|
+
}
|
|
1698
|
+
);
|
|
1607
1699
|
|
|
1608
1700
|
it('should handle a get user failure', async () => {
|
|
1609
1701
|
setup();
|
|
@@ -1618,7 +1710,6 @@ describe('plugin-meetings', () => {
|
|
|
1618
1710
|
'Failed to fetch preferred site from user - no site will be set'
|
|
1619
1711
|
);
|
|
1620
1712
|
});
|
|
1621
|
-
|
|
1622
1713
|
});
|
|
1623
1714
|
});
|
|
1624
1715
|
|
|
@@ -1714,7 +1805,7 @@ describe('plugin-meetings', () => {
|
|
|
1714
1805
|
newLocus = {
|
|
1715
1806
|
controls: {},
|
|
1716
1807
|
self: {},
|
|
1717
|
-
}
|
|
1808
|
+
};
|
|
1718
1809
|
});
|
|
1719
1810
|
afterEach(() => {
|
|
1720
1811
|
sinon.restore();
|
|
@@ -1745,16 +1836,24 @@ describe('plugin-meetings', () => {
|
|
|
1745
1836
|
});
|
|
1746
1837
|
|
|
1747
1838
|
it('if newLocus replaceAt time is expired, then return false', () => {
|
|
1748
|
-
sinon.stub(webex.meetings.meetingCollection, 'getActiveBreakoutLocus').returns({
|
|
1749
|
-
|
|
1750
|
-
|
|
1839
|
+
sinon.stub(webex.meetings.meetingCollection, 'getActiveBreakoutLocus').returns({
|
|
1840
|
+
joinedWith: {
|
|
1841
|
+
replaces: [
|
|
1842
|
+
{
|
|
1843
|
+
replaceAt: '2023-03-27T02:17:02.506Z',
|
|
1844
|
+
},
|
|
1845
|
+
],
|
|
1846
|
+
},
|
|
1847
|
+
});
|
|
1751
1848
|
newLocus.self.state = 'JOINED';
|
|
1752
1849
|
sinon.stub(MeetingsUtil, 'joinedOnThisDevice').returns(true);
|
|
1753
1850
|
sinon.stub(MeetingsUtil, 'getThisDevice').returns({
|
|
1754
|
-
replaces: [
|
|
1755
|
-
|
|
1756
|
-
|
|
1757
|
-
|
|
1851
|
+
replaces: [
|
|
1852
|
+
{
|
|
1853
|
+
replaceAt: '2023-03-27T02:17:01.506Z',
|
|
1854
|
+
},
|
|
1855
|
+
],
|
|
1856
|
+
});
|
|
1758
1857
|
|
|
1759
1858
|
LoggerProxy.logger.log = sinon.stub();
|
|
1760
1859
|
const result = webex.meetings.isNeedHandleMainLocus(meeting, newLocus);
|
|
@@ -1843,7 +1942,7 @@ describe('plugin-meetings', () => {
|
|
|
1843
1942
|
newLocus = {
|
|
1844
1943
|
controls: {},
|
|
1845
1944
|
self: {},
|
|
1846
|
-
}
|
|
1945
|
+
};
|
|
1847
1946
|
});
|
|
1848
1947
|
afterEach(() => {
|
|
1849
1948
|
sinon.restore();
|
|
@@ -1909,13 +2008,13 @@ describe('plugin-meetings', () => {
|
|
|
1909
2008
|
self: {
|
|
1910
2009
|
callbackInfo: {
|
|
1911
2010
|
callbackAddress: 'address1',
|
|
1912
|
-
}
|
|
2011
|
+
},
|
|
1913
2012
|
},
|
|
1914
2013
|
info: {
|
|
1915
2014
|
webExMeetingId: '123456',
|
|
1916
2015
|
isUnifiedSpaceMeeting: false,
|
|
1917
2016
|
},
|
|
1918
|
-
conversationUrl: 'conversationUrl1'
|
|
2017
|
+
conversationUrl: 'conversationUrl1',
|
|
1919
2018
|
};
|
|
1920
2019
|
|
|
1921
2020
|
sinon.stub(MeetingsUtil, 'checkForCorrelationId').returns('correlationId1');
|
|
@@ -1929,9 +2028,17 @@ describe('plugin-meetings', () => {
|
|
|
1929
2028
|
assert.isNull(result);
|
|
1930
2029
|
assert.callCount(webex.meetings.meetingCollection.getByKey, 5);
|
|
1931
2030
|
assert.calledWith(webex.meetings.meetingCollection.getByKey, 'locusUrl', url1);
|
|
1932
|
-
assert.calledWith(
|
|
2031
|
+
assert.calledWith(
|
|
2032
|
+
webex.meetings.meetingCollection.getByKey,
|
|
2033
|
+
'correlationId',
|
|
2034
|
+
'correlationId1'
|
|
2035
|
+
);
|
|
1933
2036
|
assert.calledWith(webex.meetings.meetingCollection.getByKey, 'sipUri', 'address1');
|
|
1934
|
-
assert.calledWith(
|
|
2037
|
+
assert.calledWith(
|
|
2038
|
+
webex.meetings.meetingCollection.getByKey,
|
|
2039
|
+
'conversationUrl',
|
|
2040
|
+
'conversationUrl1'
|
|
2041
|
+
);
|
|
1935
2042
|
assert.calledWith(webex.meetings.meetingCollection.getByKey, 'meetingNumber', '123456');
|
|
1936
2043
|
});
|
|
1937
2044
|
|
|
@@ -1941,7 +2048,7 @@ describe('plugin-meetings', () => {
|
|
|
1941
2048
|
const result = webex.meetings.getCorrespondingMeetingByLocus({locus, locusUrl: url1});
|
|
1942
2049
|
assert.isNull(result);
|
|
1943
2050
|
assert.callCount(webex.meetings.meetingCollection.getByKey, 4);
|
|
1944
|
-
})
|
|
2051
|
+
});
|
|
1945
2052
|
|
|
1946
2053
|
it('check the calls when meeting found by key: locusUrl', () => {
|
|
1947
2054
|
mockGetByKey('locusUrl');
|
|
@@ -1957,7 +2064,11 @@ describe('plugin-meetings', () => {
|
|
|
1957
2064
|
assert.deepEqual(result, mockReturnMeeting);
|
|
1958
2065
|
assert.callCount(webex.meetings.meetingCollection.getByKey, 2);
|
|
1959
2066
|
assert.calledWith(webex.meetings.meetingCollection.getByKey, 'locusUrl', url1);
|
|
1960
|
-
assert.calledWith(
|
|
2067
|
+
assert.calledWith(
|
|
2068
|
+
webex.meetings.meetingCollection.getByKey,
|
|
2069
|
+
'correlationId',
|
|
2070
|
+
'correlationId1'
|
|
2071
|
+
);
|
|
1961
2072
|
});
|
|
1962
2073
|
|
|
1963
2074
|
it('check the calls when meeting found by key: sipUri', () => {
|
|
@@ -1966,7 +2077,11 @@ describe('plugin-meetings', () => {
|
|
|
1966
2077
|
assert.deepEqual(result, mockReturnMeeting);
|
|
1967
2078
|
assert.callCount(webex.meetings.meetingCollection.getByKey, 3);
|
|
1968
2079
|
assert.calledWith(webex.meetings.meetingCollection.getByKey, 'locusUrl', url1);
|
|
1969
|
-
assert.calledWith(
|
|
2080
|
+
assert.calledWith(
|
|
2081
|
+
webex.meetings.meetingCollection.getByKey,
|
|
2082
|
+
'correlationId',
|
|
2083
|
+
'correlationId1'
|
|
2084
|
+
);
|
|
1970
2085
|
assert.calledWith(webex.meetings.meetingCollection.getByKey, 'sipUri', 'address1');
|
|
1971
2086
|
});
|
|
1972
2087
|
|
|
@@ -1976,9 +2091,17 @@ describe('plugin-meetings', () => {
|
|
|
1976
2091
|
assert.deepEqual(result, mockReturnMeeting);
|
|
1977
2092
|
assert.callCount(webex.meetings.meetingCollection.getByKey, 4);
|
|
1978
2093
|
assert.calledWith(webex.meetings.meetingCollection.getByKey, 'locusUrl', url1);
|
|
1979
|
-
assert.calledWith(
|
|
2094
|
+
assert.calledWith(
|
|
2095
|
+
webex.meetings.meetingCollection.getByKey,
|
|
2096
|
+
'correlationId',
|
|
2097
|
+
'correlationId1'
|
|
2098
|
+
);
|
|
1980
2099
|
assert.calledWith(webex.meetings.meetingCollection.getByKey, 'sipUri', 'address1');
|
|
1981
|
-
assert.calledWith(
|
|
2100
|
+
assert.calledWith(
|
|
2101
|
+
webex.meetings.meetingCollection.getByKey,
|
|
2102
|
+
'conversationUrl',
|
|
2103
|
+
'conversationUrl1'
|
|
2104
|
+
);
|
|
1982
2105
|
});
|
|
1983
2106
|
|
|
1984
2107
|
it('check the calls when meeting found by key: meetingNumber', () => {
|
|
@@ -1987,9 +2110,17 @@ describe('plugin-meetings', () => {
|
|
|
1987
2110
|
assert.deepEqual(result, mockReturnMeeting);
|
|
1988
2111
|
assert.callCount(webex.meetings.meetingCollection.getByKey, 5);
|
|
1989
2112
|
assert.calledWith(webex.meetings.meetingCollection.getByKey, 'locusUrl', url1);
|
|
1990
|
-
assert.calledWith(
|
|
2113
|
+
assert.calledWith(
|
|
2114
|
+
webex.meetings.meetingCollection.getByKey,
|
|
2115
|
+
'correlationId',
|
|
2116
|
+
'correlationId1'
|
|
2117
|
+
);
|
|
1991
2118
|
assert.calledWith(webex.meetings.meetingCollection.getByKey, 'sipUri', 'address1');
|
|
1992
|
-
assert.calledWith(
|
|
2119
|
+
assert.calledWith(
|
|
2120
|
+
webex.meetings.meetingCollection.getByKey,
|
|
2121
|
+
'conversationUrl',
|
|
2122
|
+
'conversationUrl1'
|
|
2123
|
+
);
|
|
1993
2124
|
assert.calledWith(webex.meetings.meetingCollection.getByKey, 'meetingNumber', '123456');
|
|
1994
2125
|
});
|
|
1995
2126
|
});
|
|
@@ -2004,18 +2135,18 @@ describe('plugin-meetings', () => {
|
|
|
2004
2135
|
controls: {
|
|
2005
2136
|
breakout: {
|
|
2006
2137
|
sessionType: 'MAIN',
|
|
2007
|
-
url: 'breakoutUnifiedUrl1'
|
|
2008
|
-
}
|
|
2009
|
-
}
|
|
2138
|
+
url: 'breakoutUnifiedUrl1',
|
|
2139
|
+
},
|
|
2140
|
+
},
|
|
2010
2141
|
};
|
|
2011
2142
|
breakoutLocus = {
|
|
2012
2143
|
url: 'breakoutUrl1',
|
|
2013
2144
|
controls: {
|
|
2014
2145
|
breakout: {
|
|
2015
2146
|
sessionType: 'BREAKOUT',
|
|
2016
|
-
url: 'breakoutUnifiedUrl1'
|
|
2017
|
-
}
|
|
2018
|
-
}
|
|
2147
|
+
url: 'breakoutUnifiedUrl1',
|
|
2148
|
+
},
|
|
2149
|
+
},
|
|
2019
2150
|
};
|
|
2020
2151
|
lociArray = [mainLocus, breakoutLocus];
|
|
2021
2152
|
|
|
@@ -2058,8 +2189,8 @@ describe('plugin-meetings', () => {
|
|
|
2058
2189
|
breakout: {
|
|
2059
2190
|
sessionType: 'BREAKOUT',
|
|
2060
2191
|
url: 'breakoutUnifiedUrl1',
|
|
2061
|
-
}
|
|
2062
|
-
}
|
|
2192
|
+
},
|
|
2193
|
+
},
|
|
2063
2194
|
};
|
|
2064
2195
|
|
|
2065
2196
|
webex.meetings.handleLocusEvent = sinon.stub();
|
|
@@ -2089,8 +2220,8 @@ describe('plugin-meetings', () => {
|
|
|
2089
2220
|
breakout: {
|
|
2090
2221
|
sessionType: 'MAIN',
|
|
2091
2222
|
url: 'breakoutUnifiedUrl2',
|
|
2092
|
-
}
|
|
2093
|
-
}
|
|
2223
|
+
},
|
|
2224
|
+
},
|
|
2094
2225
|
});
|
|
2095
2226
|
assert.notCalled(webex.meetings.handleLocusEvent);
|
|
2096
2227
|
});
|
|
@@ -2102,10 +2233,13 @@ describe('plugin-meetings', () => {
|
|
|
2102
2233
|
breakout: {
|
|
2103
2234
|
sessionType: 'MAIN',
|
|
2104
2235
|
url: 'breakoutUnifiedUrl1',
|
|
2105
|
-
}
|
|
2106
|
-
}
|
|
2236
|
+
},
|
|
2237
|
+
},
|
|
2238
|
+
});
|
|
2239
|
+
assert.calledWith(webex.meetings.handleLocusEvent, {
|
|
2240
|
+
locus: breakoutLocus,
|
|
2241
|
+
locusUrl: breakoutLocus.url,
|
|
2107
2242
|
});
|
|
2108
|
-
assert.calledWith(webex.meetings.handleLocusEvent, {locus: breakoutLocus, locusUrl: breakoutLocus.url});
|
|
2109
2243
|
});
|
|
2110
2244
|
});
|
|
2111
2245
|
|
|
@@ -2129,17 +2263,16 @@ describe('plugin-meetings', () => {
|
|
|
2129
2263
|
meeting.locusId = 'locus id';
|
|
2130
2264
|
meeting.correlationId = 'correlation id';
|
|
2131
2265
|
meeting.locusInfo = {
|
|
2132
|
-
fullState: {
|
|
2133
|
-
info: {
|
|
2134
|
-
}
|
|
2266
|
+
fullState: {lastActive: 'last active', sessionId: 'locus session id'},
|
|
2267
|
+
info: {webExMeetingId: 'meeting id'},
|
|
2268
|
+
};
|
|
2135
2269
|
});
|
|
2136
2270
|
|
|
2137
2271
|
afterEach(() => {
|
|
2138
2272
|
sinon.restore();
|
|
2139
|
-
})
|
|
2273
|
+
});
|
|
2140
2274
|
|
|
2141
2275
|
it('sends metrics on success', async () => {
|
|
2142
|
-
|
|
2143
2276
|
await meeting.uploadLogs();
|
|
2144
2277
|
|
|
2145
2278
|
await testUtils.flushPromises();
|
|
@@ -2162,16 +2295,20 @@ describe('plugin-meetings', () => {
|
|
|
2162
2295
|
|
|
2163
2296
|
await testUtils.flushPromises();
|
|
2164
2297
|
|
|
2165
|
-
assert.calledOnceWithExactly(
|
|
2166
|
-
|
|
2167
|
-
|
|
2168
|
-
|
|
2169
|
-
|
|
2170
|
-
|
|
2171
|
-
|
|
2172
|
-
|
|
2173
|
-
|
|
2174
|
-
|
|
2298
|
+
assert.calledOnceWithExactly(
|
|
2299
|
+
metricsSpy,
|
|
2300
|
+
'js_sdk_upload_logs_failure',
|
|
2301
|
+
sinon.match({
|
|
2302
|
+
callStart: 'last active',
|
|
2303
|
+
correlationId: 'correlation id',
|
|
2304
|
+
feedbackId: 'correlation id',
|
|
2305
|
+
locusId: 'locus id',
|
|
2306
|
+
meetingId: 'meeting id',
|
|
2307
|
+
reason: 'fake error',
|
|
2308
|
+
autoupload: true,
|
|
2309
|
+
locussessionid: 'locus session id',
|
|
2310
|
+
})
|
|
2311
|
+
);
|
|
2175
2312
|
});
|
|
2176
2313
|
});
|
|
2177
2314
|
});
|