@webex/plugin-meetings 3.7.0-next.5 → 3.7.0-next.6

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 (32) hide show
  1. package/dist/breakouts/breakout.js +1 -1
  2. package/dist/breakouts/index.js +1 -1
  3. package/dist/constants.js +4 -0
  4. package/dist/constants.js.map +1 -1
  5. package/dist/interpretation/index.js +1 -1
  6. package/dist/interpretation/siLanguage.js +1 -1
  7. package/dist/meeting/in-meeting-actions.js +2 -0
  8. package/dist/meeting/in-meeting-actions.js.map +1 -1
  9. package/dist/meeting/index.js +1 -0
  10. package/dist/meeting/index.js.map +1 -1
  11. package/dist/recording-controller/enums.js +8 -4
  12. package/dist/recording-controller/enums.js.map +1 -1
  13. package/dist/recording-controller/index.js +18 -9
  14. package/dist/recording-controller/index.js.map +1 -1
  15. package/dist/recording-controller/util.js +13 -9
  16. package/dist/recording-controller/util.js.map +1 -1
  17. package/dist/types/constants.d.ts +4 -0
  18. package/dist/types/meeting/in-meeting-actions.d.ts +2 -0
  19. package/dist/types/recording-controller/enums.d.ts +5 -2
  20. package/dist/types/recording-controller/index.d.ts +1 -0
  21. package/dist/types/recording-controller/util.d.ts +2 -1
  22. package/dist/webinar/index.js +1 -1
  23. package/package.json +21 -21
  24. package/src/constants.ts +4 -0
  25. package/src/meeting/in-meeting-actions.ts +4 -0
  26. package/src/meeting/index.ts +4 -0
  27. package/src/recording-controller/enums.ts +5 -2
  28. package/src/recording-controller/index.ts +17 -4
  29. package/src/recording-controller/util.ts +20 -5
  30. package/test/unit/spec/meeting/in-meeting-actions.ts +2 -0
  31. package/test/unit/spec/recording-controller/index.js +61 -5
  32. package/test/unit/spec/recording-controller/util.js +39 -3
@@ -221,7 +221,21 @@ describe('plugin-meetings', () => {
221
221
 
222
222
  assert.calledWith(request.request, {
223
223
  uri: `test/loci/id/recording`,
224
- body: {meetingInfo: {locusSessionId: 'testId'}, recording: {action: 'start'}},
224
+ body: {meetingInfo: {locusSessionId: 'testId'}, recording: {action: 'start'}, recordingType: 'cloud'},
225
+ method: HTTP_VERBS.PUT,
226
+ });
227
+
228
+ assert.deepEqual(result, request.request.firstCall.returnValue);
229
+ });
230
+
231
+ it('can start premise recording when the correct display hint is present', () => {
232
+ controller.setDisplayHints(['PREMISE_RECORDING_CONTROL_START']);
233
+
234
+ const result = controller.startRecording();
235
+
236
+ assert.calledWith(request.request, {
237
+ uri: `test/loci/id/recording`,
238
+ body: {meetingInfo: {locusSessionId: 'testId'}, recording: {action: 'start'}, recordingType: 'premise'},
225
239
  method: HTTP_VERBS.PUT,
226
240
  });
227
241
 
@@ -238,14 +252,28 @@ describe('plugin-meetings', () => {
238
252
  assert.isRejected(result);
239
253
  });
240
254
 
241
- it('can start recording when the correct display hint is present', () => {
255
+ it('can stop recording when the correct display hint is present', () => {
242
256
  controller.setDisplayHints(['RECORDING_CONTROL_STOP']);
243
257
 
244
258
  const result = controller.stopRecording();
245
259
 
246
260
  assert.calledWith(request.request, {
247
261
  uri: `test/loci/id/recording`,
248
- body: {meetingInfo: {locusSessionId: 'testId'}, recording: {action: 'stop'}},
262
+ body: {meetingInfo: {locusSessionId: 'testId'}, recording: {action: 'stop'}, recordingType: 'cloud'},
263
+ method: HTTP_VERBS.PUT,
264
+ });
265
+
266
+ assert.deepEqual(result, request.request.firstCall.returnValue);
267
+ });
268
+
269
+ it('can stop premise recording when the correct display hint is present', () => {
270
+ controller.setDisplayHints(['PREMISE_RECORDING_CONTROL_STOP']);
271
+
272
+ const result = controller.stopRecording();
273
+
274
+ assert.calledWith(request.request, {
275
+ uri: `test/loci/id/recording`,
276
+ body: {meetingInfo: {locusSessionId: 'testId'}, recording: {action: 'stop'}, recordingType: 'premise'},
249
277
  method: HTTP_VERBS.PUT,
250
278
  });
251
279
 
@@ -269,7 +297,21 @@ describe('plugin-meetings', () => {
269
297
 
270
298
  assert.calledWith(request.request, {
271
299
  uri: `test/loci/id/recording`,
272
- body: {meetingInfo: {locusSessionId: 'testId'}, recording: {action: 'pause'}},
300
+ body: {meetingInfo: {locusSessionId: 'testId'}, recording: {action: 'pause'}, recordingType: 'cloud'},
301
+ method: HTTP_VERBS.PUT,
302
+ });
303
+
304
+ assert.deepEqual(result, request.request.firstCall.returnValue);
305
+ });
306
+
307
+ it('can pause premise recording when the correct display hint is present', () => {
308
+ controller.setDisplayHints(['PREMISE_RECORDING_CONTROL_PAUSE']);
309
+
310
+ const result = controller.pauseRecording();
311
+
312
+ assert.calledWith(request.request, {
313
+ uri: `test/loci/id/recording`,
314
+ body: {meetingInfo: {locusSessionId: 'testId'}, recording: {action: 'pause'}, recordingType: 'premise'},
273
315
  method: HTTP_VERBS.PUT,
274
316
  });
275
317
 
@@ -293,7 +335,21 @@ describe('plugin-meetings', () => {
293
335
 
294
336
  assert.calledWith(request.request, {
295
337
  uri: `test/loci/id/recording`,
296
- body: {meetingInfo: {locusSessionId: 'testId'}, recording: {action: 'resume'}},
338
+ body: {meetingInfo: {locusSessionId: 'testId'}, recording: {action: 'resume'}, recordingType: 'cloud'},
339
+ method: HTTP_VERBS.PUT,
340
+ });
341
+
342
+ assert.deepEqual(result, request.request.firstCall.returnValue);
343
+ });
344
+
345
+ it('can resume premise recording when the correct display hint is present', () => {
346
+ controller.setDisplayHints(['PREMISE_RECORDING_CONTROL_RESUME']);
347
+
348
+ const result = controller.resumeRecording();
349
+
350
+ assert.calledWith(request.request, {
351
+ uri: `test/loci/id/recording`,
352
+ body: {meetingInfo: {locusSessionId: 'testId'}, recording: {action: 'resume'}, recordingType: 'premise'},
297
353
  method: HTTP_VERBS.PUT,
298
354
  });
299
355
 
@@ -1,5 +1,5 @@
1
1
  import RecordingUtil from '@webex/plugin-meetings/src/recording-controller/util';
2
- import RecordingAction from '@webex/plugin-meetings/src/recording-controller/enums';
2
+ import { RecordingAction } from '@webex/plugin-meetings/src/recording-controller/enums';
3
3
  import {SELF_POLICY} from '@webex/plugin-meetings/src/constants';
4
4
 
5
5
  import {assert} from 'chai';
@@ -29,6 +29,15 @@ describe('plugin-meetings', () => {
29
29
  );
30
30
  });
31
31
 
32
+ it('can start premise recording when the correct display hint is present', () => {
33
+ locusInfo.parsedLocus.info.userDisplayHints.push('PREMISE_RECORDING_CONTROL_START');
34
+
35
+ assert.equal(
36
+ RecordingUtil.canUserStart(locusInfo.parsedLocus.info.userDisplayHints),
37
+ true
38
+ );
39
+ });
40
+
32
41
  it('can start recording when the correct display hint is present and the policy is true', () => {
33
42
  locusInfo.parsedLocus.info.userDisplayHints.push('RECORDING_CONTROL_START');
34
43
 
@@ -69,6 +78,15 @@ describe('plugin-meetings', () => {
69
78
  );
70
79
  });
71
80
 
81
+ it('can pause premise recording when the correct display hint is present', () => {
82
+ locusInfo.parsedLocus.info.userDisplayHints.push('PREMISE_RECORDING_CONTROL_PAUSE');
83
+
84
+ assert.equal(
85
+ RecordingUtil.canUserPause(locusInfo.parsedLocus.info.userDisplayHints),
86
+ true
87
+ );
88
+ });
89
+
72
90
  it('can pause recording when the correct display hint is present and the policy is true', () => {
73
91
  locusInfo.parsedLocus.info.userDisplayHints.push('RECORDING_CONTROL_PAUSE');
74
92
 
@@ -109,6 +127,15 @@ describe('plugin-meetings', () => {
109
127
  );
110
128
  });
111
129
 
130
+ it('can stop premise recording when the correct display hint is present', () => {
131
+ locusInfo.parsedLocus.info.userDisplayHints.push('PREMISE_RECORDING_CONTROL_STOP');
132
+
133
+ assert.equal(
134
+ RecordingUtil.canUserStop(locusInfo.parsedLocus.info.userDisplayHints),
135
+ true
136
+ );
137
+ });
138
+
112
139
  it('can stop recording when the correct display hint is present and the policy is true', () => {
113
140
  locusInfo.parsedLocus.info.userDisplayHints.push('RECORDING_CONTROL_STOP', {
114
141
  [SELF_POLICY.SUPPORT_NETWORK_BASED_RECORD]: true,
@@ -142,7 +169,7 @@ describe('plugin-meetings', () => {
142
169
  });
143
170
 
144
171
  describe('canUserResume', () => {
145
- it('can start recording when the correct display hint is present', () => {
172
+ it('can resume recording when the correct display hint is present', () => {
146
173
  locusInfo.parsedLocus.info.userDisplayHints.push('RECORDING_CONTROL_RESUME');
147
174
 
148
175
  assert.equal(
@@ -151,7 +178,16 @@ describe('plugin-meetings', () => {
151
178
  );
152
179
  });
153
180
 
154
- it('can start recording when the correct display hint is present and the policy is true', () => {
181
+ it('can resume premise recording when the correct display hint is present', () => {
182
+ locusInfo.parsedLocus.info.userDisplayHints.push('PREMISE_RECORDING_CONTROL_RESUME');
183
+
184
+ assert.equal(
185
+ RecordingUtil.canUserResume(locusInfo.parsedLocus.info.userDisplayHints),
186
+ true
187
+ );
188
+ });
189
+
190
+ it('can resume recording when the correct display hint is present and the policy is true', () => {
155
191
  locusInfo.parsedLocus.info.userDisplayHints.push('RECORDING_CONTROL_RESUME');
156
192
 
157
193
  assert.equal(