@webex/plugin-meetings 3.0.0-beta.146 → 3.0.0-beta.148

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.
Files changed (60) hide show
  1. package/dist/annotation/index.js +0 -2
  2. package/dist/annotation/index.js.map +1 -1
  3. package/dist/breakouts/breakout.js +1 -1
  4. package/dist/breakouts/index.js +1 -1
  5. package/dist/common/errors/webex-errors.js +3 -2
  6. package/dist/common/errors/webex-errors.js.map +1 -1
  7. package/dist/config.js +1 -7
  8. package/dist/config.js.map +1 -1
  9. package/dist/constants.js +7 -15
  10. package/dist/constants.js.map +1 -1
  11. package/dist/index.js +6 -0
  12. package/dist/index.js.map +1 -1
  13. package/dist/media/index.js +5 -56
  14. package/dist/media/index.js.map +1 -1
  15. package/dist/media/properties.js +15 -93
  16. package/dist/media/properties.js.map +1 -1
  17. package/dist/meeting/index.js +1112 -1873
  18. package/dist/meeting/index.js.map +1 -1
  19. package/dist/meeting/muteState.js +88 -184
  20. package/dist/meeting/muteState.js.map +1 -1
  21. package/dist/meeting/util.js +1 -23
  22. package/dist/meeting/util.js.map +1 -1
  23. package/dist/meetings/index.js +1 -2
  24. package/dist/meetings/index.js.map +1 -1
  25. package/dist/reconnection-manager/index.js +153 -134
  26. package/dist/reconnection-manager/index.js.map +1 -1
  27. package/dist/roap/index.js +8 -7
  28. package/dist/roap/index.js.map +1 -1
  29. package/dist/types/common/errors/webex-errors.d.ts +1 -1
  30. package/dist/types/config.d.ts +0 -6
  31. package/dist/types/constants.d.ts +1 -18
  32. package/dist/types/index.d.ts +1 -1
  33. package/dist/types/media/properties.d.ts +16 -38
  34. package/dist/types/meeting/index.d.ts +97 -353
  35. package/dist/types/meeting/muteState.d.ts +36 -38
  36. package/dist/types/meeting/util.d.ts +2 -4
  37. package/package.json +19 -19
  38. package/src/annotation/index.ts +0 -2
  39. package/src/common/errors/webex-errors.ts +6 -2
  40. package/src/config.ts +0 -6
  41. package/src/constants.ts +1 -14
  42. package/src/index.ts +1 -0
  43. package/src/media/index.ts +10 -53
  44. package/src/media/properties.ts +32 -92
  45. package/src/meeting/index.ts +544 -1567
  46. package/src/meeting/muteState.ts +87 -178
  47. package/src/meeting/util.ts +3 -24
  48. package/src/meetings/index.ts +0 -1
  49. package/src/reconnection-manager/index.ts +4 -9
  50. package/src/roap/index.ts +13 -14
  51. package/test/integration/spec/converged-space-meetings.js +59 -3
  52. package/test/integration/spec/journey.js +330 -256
  53. package/test/integration/spec/space-meeting.js +75 -3
  54. package/test/unit/spec/annotation/index.ts +4 -4
  55. package/test/unit/spec/meeting/index.js +811 -1367
  56. package/test/unit/spec/meeting/muteState.js +238 -394
  57. package/test/unit/spec/meeting/utils.js +2 -9
  58. package/test/unit/spec/multistream/receiveSlot.ts +1 -1
  59. package/test/unit/spec/roap/index.ts +2 -2
  60. package/test/utils/integrationTestUtils.js +5 -23
@@ -3,6 +3,7 @@ import {assert} from '@webex/test-helper-chai';
3
3
  import {skipInNode, jenkinsOnly} from '@webex/test-helper-mocha';
4
4
  import {patterns} from '@webex/common';
5
5
  import MeetingInfoUtil from '@webex/plugin-meetings/dist/meeting-info/utilv2';
6
+ import {createCameraTrack, createMicrophoneTrack} from '@webex/plugin-meetings';
6
7
 
7
8
  import CMR from '../../utils/cmr';
8
9
  import testUtils from '../../utils/testUtils';
@@ -14,6 +15,21 @@ const webexTestUsers = require('../../utils/webex-test-users');
14
15
 
15
16
  let userSet, alice, bob, chris, guest;
16
17
 
18
+ const localTracks = {
19
+ alice: {
20
+ microphone: undefined,
21
+ camera: undefined,
22
+ },
23
+ bob: {
24
+ microphone: undefined,
25
+ camera: undefined,
26
+ },
27
+ guest: {
28
+ microphone: undefined,
29
+ camera: undefined,
30
+ },
31
+ };
32
+
17
33
  skipInNode(describe)('plugin-meetings', () => {
18
34
  describe('space-meeting', () => {
19
35
  let space = null;
@@ -136,8 +152,17 @@ skipInNode(describe)('plugin-meetings', () => {
136
152
  .then(() => testUtils.waitForStateChange(bob.meeting, 'JOINED'))
137
153
  .then(() => testUtils.waitForStateChange(chris.meeting, 'JOINED')));
138
154
 
155
+ it('Bob and Alice create local microphone and camera tracks', async () => {
156
+ localTracks.alice.microphone = await createMicrophoneTrack();
157
+ localTracks.alice.camera = await createCameraTrack();
158
+
159
+ localTracks.bob.microphone = await createMicrophoneTrack();
160
+ localTracks.bob.camera = await createCameraTrack();
161
+ });
162
+
139
163
  it('Bob and Alice addsMedia', () =>
140
- integrationTestUtils.addMedia(bob).then(() => integrationTestUtils.addMedia(alice)));
164
+ integrationTestUtils.addMedia(bob, {microphone: localTracks.bob.microphone, camera: localTracks.bob.camera})
165
+ .then(() => integrationTestUtils.addMedia(alice, {microphone: localTracks.alice.microphone, camera: localTracks.alice.camera})));
141
166
 
142
167
  it('Bob has flowing streams on reconnect', () => {
143
168
  const retrieveStats = () => {
@@ -188,7 +213,11 @@ skipInNode(describe)('plugin-meetings', () => {
188
213
  ])
189
214
  )
190
215
  .then(() => testUtils.waitForStateChange(guest.meeting, 'JOINED'))
191
- .then(() => integrationTestUtils.addMedia(guest))
216
+ .then(async () => {
217
+ localTracks.guest.microphone = await createMicrophoneTrack();
218
+ localTracks.guest.camera = await createCameraTrack();
219
+ })
220
+ .then(() => integrationTestUtils.addMedia(guest, {microphone: localTracks.guest.microphone, camera: localTracks.guest.camera}))
192
221
  .catch((e) => {
193
222
  console.error('Error chris joining the meeting ', e);
194
223
  throw e;
@@ -221,6 +250,35 @@ skipInNode(describe)('plugin-meetings', () => {
221
250
  .then(() => chris.meeting.leave())
222
251
  .then(() => testUtils.waitUntil(4000)));
223
252
 
253
+ it('alice, bob and chris stop all local tracks', () => {
254
+ if (localTracks.alice.microphone) {
255
+ localTracks.alice.microphone.stop();
256
+ localTracks.alice.microphone = undefined;
257
+ }
258
+ if (localTracks.alice.camera) {
259
+ localTracks.alice.camera.stop();
260
+ localTracks.alice.camera = undefined;
261
+ }
262
+
263
+ if (localTracks.bob.microphone) {
264
+ localTracks.bob.microphone.stop();
265
+ localTracks.bob.microphone = undefined;
266
+ }
267
+ if (localTracks.bob.camera) {
268
+ localTracks.bob.camera.stop();
269
+ localTracks.bob.camera = undefined;
270
+ }
271
+
272
+ if (localTracks.guest.microphone) {
273
+ localTracks.guest.microphone.stop();
274
+ localTracks.guest.microphone = undefined;
275
+ }
276
+ if (localTracks.guest.camera) {
277
+ localTracks.guest.camera.stop();
278
+ localTracks.guest.camera = undefined;
279
+ }
280
+ });
281
+
224
282
  it('check for meeting cleanup', () => {
225
283
  console.log('Alice ', alice.webex.meetings.getAllMeetings());
226
284
  console.log('Bob ', bob.webex.meetings.getAllMeetings());
@@ -415,7 +473,11 @@ skipInNode(describe)('plugin-meetings', () => {
415
473
  }),
416
474
  ])
417
475
  .then(() => testUtils.waitForStateChange(guest.meeting, 'JOINED'))
418
- .then(() => integrationTestUtils.addMedia(guest));
476
+ .then(async () => {
477
+ localTracks.guest.microphone = await createMicrophoneTrack();
478
+ localTracks.guest.camera = await createCameraTrack();
479
+ })
480
+ .then(() => integrationTestUtils.addMedia(guest, {microphone: localTracks.guest.microphone, camera: localTracks.guest.camera}));
419
481
  })
420
482
  .catch((e) => {
421
483
  console.error('Error guest joining the meeting ', e);
@@ -452,6 +514,16 @@ skipInNode(describe)('plugin-meetings', () => {
452
514
  testUtils.waitForCallEnded(bob, alice.sipAddress),
453
515
  testUtils.waitForCallEnded(chris, alice.sipAddress),
454
516
  ])
517
+ .then(() => {
518
+ if (localTracks.guest.microphone) {
519
+ localTracks.guest.microphone.stop();
520
+ localTracks.guest.microphone = undefined;
521
+ }
522
+ if (localTracks.guest.camera) {
523
+ localTracks.guest.camera.stop();
524
+ localTracks.guest.camera = undefined;
525
+ }
526
+ })
455
527
  ));
456
528
  });
457
529
  });
@@ -189,7 +189,7 @@ describe('live-annotation', () => {
189
189
  });
190
190
 
191
191
 
192
- describe('encrypt/decrypt Content ', () => {
192
+ describe('encrypt/decrypt Content', () => {
193
193
  beforeEach(async () => {
194
194
  annotationService.webex.internal.encryption.encryptText = sinon.stub().returns(Promise.resolve('RETURN_VALUE'));
195
195
  annotationService.webex.internal.encryption.decryptText = sinon.stub().returns(Promise.resolve('RETURN_VALUE'));
@@ -201,7 +201,7 @@ describe('live-annotation', () => {
201
201
  assert.equal(result, 'RETURN_VALUE')
202
202
  });
203
203
 
204
- it('decryptContent ', async() => {
204
+ it('decryptContent', async() => {
205
205
  const result = await annotationService.decryptContent("decryptionKeyUrl", "content");
206
206
  assert.calledOnceWithExactly(webex.internal.encryption.decryptText, "decryptionKeyUrl", "content");
207
207
  assert.equal(result, 'RETURN_VALUE')
@@ -232,7 +232,7 @@ describe('live-annotation', () => {
232
232
  });
233
233
 
234
234
 
235
- it('works on publish Stroke Data', async () => {
235
+ it('works on publish Stroke Data', async () => {
236
236
  const strokeData = {
237
237
  content: {
238
238
  "contentsBuffer": [{
@@ -343,7 +343,7 @@ describe('live-annotation', () => {
343
343
  });
344
344
  });
345
345
 
346
- describe('change annotation options', () => {
346
+ describe('change annotation info by presenter', () => {
347
347
  it('makes change annotation options as expected', async() => {
348
348
  const options = { annotationInfo:{
349
349
  version: '1',