@webex/plugin-meetings 3.8.0-next.7 → 3.8.0-next.70
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/breakout.js +1 -1
- package/dist/breakouts/index.js +1 -1
- package/dist/common/errors/webex-errors.js +12 -2
- package/dist/common/errors/webex-errors.js.map +1 -1
- package/dist/config.js +4 -1
- package/dist/config.js.map +1 -1
- package/dist/constants.js +17 -121
- package/dist/constants.js.map +1 -1
- package/dist/controls-options-manager/enums.js +2 -0
- package/dist/controls-options-manager/enums.js.map +1 -1
- package/dist/controls-options-manager/types.js.map +1 -1
- package/dist/controls-options-manager/util.js +52 -0
- package/dist/controls-options-manager/util.js.map +1 -1
- package/dist/interpretation/index.js +1 -1
- package/dist/interpretation/siLanguage.js +1 -1
- package/dist/locus-info/controlsUtils.js +28 -10
- package/dist/locus-info/controlsUtils.js.map +1 -1
- package/dist/locus-info/index.js +20 -1
- package/dist/locus-info/index.js.map +1 -1
- package/dist/locus-info/selfUtils.js +405 -418
- package/dist/locus-info/selfUtils.js.map +1 -1
- package/dist/media/index.js +14 -16
- package/dist/media/index.js.map +1 -1
- package/dist/media/properties.js +94 -6
- package/dist/media/properties.js.map +1 -1
- package/dist/meeting/brbState.js +6 -0
- package/dist/meeting/brbState.js.map +1 -1
- package/dist/meeting/in-meeting-actions.js +17 -1
- package/dist/meeting/in-meeting-actions.js.map +1 -1
- package/dist/meeting/index.js +541 -302
- package/dist/meeting/index.js.map +1 -1
- package/dist/meeting/locusMediaRequest.js +0 -17
- package/dist/meeting/locusMediaRequest.js.map +1 -1
- package/dist/meeting/muteState.js +0 -2
- package/dist/meeting/muteState.js.map +1 -1
- package/dist/meeting/request.js +30 -0
- package/dist/meeting/request.js.map +1 -1
- package/dist/meeting/request.type.js.map +1 -1
- package/dist/meeting/util.js +13 -2
- package/dist/meeting/util.js.map +1 -1
- package/dist/meeting-info/meeting-info-v2.js +359 -60
- package/dist/meeting-info/meeting-info-v2.js.map +1 -1
- package/dist/meetings/index.js +114 -1
- package/dist/meetings/index.js.map +1 -1
- package/dist/meetings/util.js +14 -0
- package/dist/meetings/util.js.map +1 -1
- package/dist/member/index.js +10 -0
- package/dist/member/index.js.map +1 -1
- package/dist/member/util.js +330 -353
- package/dist/member/util.js.map +1 -1
- package/dist/members/index.js +23 -0
- package/dist/members/index.js.map +1 -1
- package/dist/members/request.js +21 -0
- package/dist/members/request.js.map +1 -1
- package/dist/members/util.js +15 -0
- package/dist/members/util.js.map +1 -1
- package/dist/metrics/constants.js +9 -0
- package/dist/metrics/constants.js.map +1 -1
- package/dist/reachability/clusterReachability.js +63 -27
- package/dist/reachability/clusterReachability.js.map +1 -1
- package/dist/reachability/index.js +112 -47
- package/dist/reachability/index.js.map +1 -1
- package/dist/reachability/reachability.types.js +14 -0
- package/dist/reachability/reachability.types.js.map +1 -1
- package/dist/reachability/request.js +19 -3
- package/dist/reachability/request.js.map +1 -1
- package/dist/reconnection-manager/index.js +2 -2
- package/dist/reconnection-manager/index.js.map +1 -1
- package/dist/recording-controller/util.js +5 -5
- package/dist/recording-controller/util.js.map +1 -1
- package/dist/roap/index.js.map +1 -1
- package/dist/roap/turnDiscovery.js +45 -27
- package/dist/roap/turnDiscovery.js.map +1 -1
- package/dist/roap/types.js +17 -0
- package/dist/roap/types.js.map +1 -0
- package/dist/types/common/errors/webex-errors.d.ts +7 -1
- package/dist/types/config.d.ts +2 -0
- package/dist/types/constants.d.ts +12 -85
- package/dist/types/controls-options-manager/enums.d.ts +3 -1
- package/dist/types/controls-options-manager/types.d.ts +7 -1
- package/dist/types/locus-info/index.d.ts +1 -0
- package/dist/types/locus-info/selfUtils.d.ts +247 -1
- package/dist/types/media/properties.d.ts +15 -0
- package/dist/types/meeting/in-meeting-actions.d.ts +16 -0
- package/dist/types/meeting/index.d.ts +32 -1
- package/dist/types/meeting/muteState.d.ts +0 -1
- package/dist/types/meeting/request.d.ts +12 -1
- package/dist/types/meeting/request.type.d.ts +6 -0
- package/dist/types/meeting/util.d.ts +3 -1
- package/dist/types/meeting-info/meeting-info-v2.d.ts +80 -0
- package/dist/types/meetings/index.d.ts +48 -0
- package/dist/types/member/index.d.ts +1 -0
- package/dist/types/member/util.d.ts +159 -1
- package/dist/types/members/index.d.ts +8 -0
- package/dist/types/members/request.d.ts +19 -0
- package/dist/types/members/util.d.ts +13 -0
- package/dist/types/metrics/constants.d.ts +9 -0
- package/dist/types/reachability/clusterReachability.d.ts +15 -7
- package/dist/types/reachability/index.d.ts +10 -1
- package/dist/types/reachability/reachability.types.d.ts +5 -0
- package/dist/types/roap/index.d.ts +3 -2
- package/dist/types/roap/turnDiscovery.d.ts +5 -17
- package/dist/types/roap/types.d.ts +16 -0
- package/dist/webinar/index.js +1 -1
- package/package.json +24 -23
- package/src/common/errors/webex-errors.ts +8 -1
- package/src/config.ts +2 -0
- package/src/constants.ts +19 -90
- package/src/controls-options-manager/enums.ts +2 -0
- package/src/controls-options-manager/types.ts +11 -1
- package/src/controls-options-manager/util.ts +62 -0
- package/src/locus-info/controlsUtils.ts +44 -14
- package/src/locus-info/index.ts +23 -1
- package/src/locus-info/selfUtils.ts +451 -447
- package/src/media/index.ts +20 -21
- package/src/media/properties.ts +96 -0
- package/src/meeting/brbState.ts +7 -0
- package/src/meeting/in-meeting-actions.ts +32 -0
- package/src/meeting/index.ts +346 -93
- package/src/meeting/locusMediaRequest.ts +0 -18
- package/src/meeting/muteState.ts +0 -2
- package/src/meeting/request.ts +36 -1
- package/src/meeting/request.type.ts +7 -0
- package/src/meeting/util.ts +11 -2
- package/src/meeting-info/meeting-info-v2.ts +247 -6
- package/src/meetings/index.ts +128 -1
- package/src/meetings/util.ts +18 -0
- package/src/member/index.ts +13 -2
- package/src/member/util.ts +351 -348
- package/src/members/index.ts +25 -0
- package/src/members/request.ts +26 -0
- package/src/members/util.ts +16 -0
- package/src/metrics/constants.ts +9 -0
- package/src/reachability/clusterReachability.ts +73 -26
- package/src/reachability/index.ts +70 -1
- package/src/reachability/reachability.types.ts +6 -0
- package/src/reachability/request.ts +7 -0
- package/src/reconnection-manager/index.ts +2 -2
- package/src/recording-controller/util.ts +17 -13
- package/src/roap/index.ts +3 -7
- package/src/roap/turnDiscovery.ts +34 -39
- package/src/roap/types.ts +23 -0
- package/test/unit/spec/controls-options-manager/util.js +120 -0
- package/test/unit/spec/locus-info/controlsUtils.js +103 -9
- package/test/unit/spec/locus-info/index.js +28 -0
- package/test/unit/spec/media/index.ts +98 -16
- package/test/unit/spec/media/properties.ts +130 -0
- package/test/unit/spec/meeting/brbState.ts +19 -0
- package/test/unit/spec/meeting/in-meeting-actions.ts +19 -4
- package/test/unit/spec/meeting/index.js +524 -35
- package/test/unit/spec/meeting/locusMediaRequest.ts +0 -30
- package/test/unit/spec/meeting/muteState.js +0 -2
- package/test/unit/spec/meeting/request.js +32 -1
- package/test/unit/spec/meeting/utils.js +119 -18
- package/test/unit/spec/meeting-info/meetinginfov2.js +443 -114
- package/test/unit/spec/meetings/index.js +133 -2
- package/test/unit/spec/member/index.js +7 -0
- package/test/unit/spec/member/util.js +24 -0
- package/test/unit/spec/members/index.js +103 -26
- package/test/unit/spec/members/request.js +45 -22
- package/test/unit/spec/members/utils.js +33 -0
- package/test/unit/spec/reachability/clusterReachability.ts +88 -56
- package/test/unit/spec/reachability/index.ts +101 -0
- package/test/unit/spec/reachability/request.js +47 -2
- package/test/unit/spec/reconnection-manager/index.js +4 -4
- package/test/unit/spec/roap/turnDiscovery.ts +110 -28
@@ -2,6 +2,7 @@ import 'jsdom-global/register';
|
|
2
2
|
import {assert} from '@webex/test-helper-chai';
|
3
3
|
import sinon from 'sinon';
|
4
4
|
import {ConnectionState} from '@webex/internal-media-core';
|
5
|
+
import * as tsSdpModule from '@webex/ts-sdp';
|
5
6
|
import MediaProperties from '@webex/plugin-meetings/src/media/properties';
|
6
7
|
import {Defer} from '@webex/common';
|
7
8
|
import MediaConnectionAwaiter from '../../../../src/media/MediaConnectionAwaiter';
|
@@ -10,15 +11,21 @@ describe('MediaProperties', () => {
|
|
10
11
|
let mediaProperties;
|
11
12
|
let mockMC;
|
12
13
|
let clock;
|
14
|
+
let rtcPeerConnection;
|
13
15
|
|
14
16
|
beforeEach(() => {
|
15
17
|
clock = sinon.useFakeTimers();
|
16
18
|
|
19
|
+
rtcPeerConnection = {
|
20
|
+
localDescription: {sdp: ''},
|
21
|
+
};
|
22
|
+
|
17
23
|
mockMC = {
|
18
24
|
getStats: sinon.stub().resolves([]),
|
19
25
|
on: sinon.stub(),
|
20
26
|
off: sinon.stub(),
|
21
27
|
getConnectionState: sinon.stub().returns(ConnectionState.Connected),
|
28
|
+
multistreamConnection: {pc: {pc: rtcPeerConnection}},
|
22
29
|
};
|
23
30
|
|
24
31
|
mediaProperties = new MediaProperties();
|
@@ -81,6 +88,129 @@ describe('MediaProperties', () => {
|
|
81
88
|
assert.equal(numTransports, 0);
|
82
89
|
});
|
83
90
|
|
91
|
+
describe('ipVersion', () => {
|
92
|
+
it('returns ipVersion=undefined if getStats() returns no candidate pairs', async () => {
|
93
|
+
mockMC.getStats.resolves([{type: 'something', id: '1234'}]);
|
94
|
+
const info = await mediaProperties.getCurrentConnectionInfo();
|
95
|
+
assert.equal(info.ipVersion, undefined);
|
96
|
+
});
|
97
|
+
|
98
|
+
it('returns ipVersion=undefined if getStats() returns no selected candidate pair', async () => {
|
99
|
+
mockMC.getStats.resolves([{type: 'candidate-pair', id: '1234', selected: false}]);
|
100
|
+
const info = await mediaProperties.getCurrentConnectionInfo();
|
101
|
+
assert.equal(info.ipVersion, undefined);
|
102
|
+
});
|
103
|
+
|
104
|
+
it('returns ipVersion="IPv4" if transport has selectedCandidatePairId and local candidate has IPv4 address', async () => {
|
105
|
+
mockMC.getStats.resolves([
|
106
|
+
{type: 'transport', id: 't1', selectedCandidatePairId: 'cp1'},
|
107
|
+
{type: 'candidate-pair', id: 'cp1', localCandidateId: 'lc1'},
|
108
|
+
{type: 'local-candidate', id: 'lc1', address: '192.168.1.1'},
|
109
|
+
]);
|
110
|
+
const info = await mediaProperties.getCurrentConnectionInfo();
|
111
|
+
assert.equal(info.ipVersion, 'IPv4');
|
112
|
+
});
|
113
|
+
|
114
|
+
it('returns ipVersion="IPv6" if transport has selectedCandidatePairId and local candidate has IPv6 address', async () => {
|
115
|
+
mockMC.getStats.resolves([
|
116
|
+
{type: 'transport', id: 't1', selectedCandidatePairId: 'cp1'},
|
117
|
+
{type: 'candidate-pair', id: 'cp1', localCandidateId: 'lc1'},
|
118
|
+
{type: 'local-candidate', id: 'lc1', address: 'fd8f:12e6:5e53:784f:a0ba:f8d5:b906:1acc'},
|
119
|
+
]);
|
120
|
+
const info = await mediaProperties.getCurrentConnectionInfo();
|
121
|
+
assert.equal(info.ipVersion, 'IPv6');
|
122
|
+
});
|
123
|
+
|
124
|
+
it('returns ipVersion="IPv4" if transport has no selectedCandidatePairId but finds selected candidate pair and local candidate has IPv4 address', async () => {
|
125
|
+
mockMC.getStats.resolves([
|
126
|
+
{type: 'transport', id: 't1'},
|
127
|
+
{type: 'candidate-pair', id: 'cp2', localCandidateId: 'lc2', selected: true},
|
128
|
+
{type: 'local-candidate', id: 'lc2', address: '10.0.0.1'},
|
129
|
+
]);
|
130
|
+
const info = await mediaProperties.getCurrentConnectionInfo();
|
131
|
+
assert.equal(info.ipVersion, 'IPv4');
|
132
|
+
});
|
133
|
+
|
134
|
+
it('returns ipVersion="IPv6" if transport has no selectedCandidatePairId but finds selected candidate pair and local candidate has IPv6 address', async () => {
|
135
|
+
mockMC.getStats.resolves([
|
136
|
+
{type: 'transport', id: 't1'},
|
137
|
+
{type: 'candidate-pair', id: 'cp2', localCandidateId: 'lc2', selected: true},
|
138
|
+
{type: 'local-candidate', id: 'lc2', address: 'fe80::1ff:fe23:4567:890a'},
|
139
|
+
]);
|
140
|
+
const info = await mediaProperties.getCurrentConnectionInfo();
|
141
|
+
assert.equal(info.ipVersion, 'IPv6');
|
142
|
+
});
|
143
|
+
|
144
|
+
describe('local candidate without address', () => {
|
145
|
+
it('return="IPv4" if candidate from SDP with matching port number has IPv4 address', async () => {
|
146
|
+
sinon.stub(tsSdpModule, 'parse').returns({
|
147
|
+
avMedia: [
|
148
|
+
{
|
149
|
+
iceInfo: {
|
150
|
+
candidates: [
|
151
|
+
{
|
152
|
+
port: 1234,
|
153
|
+
connectionAddress: '192.168.0.1',
|
154
|
+
},
|
155
|
+
],
|
156
|
+
},
|
157
|
+
},
|
158
|
+
],
|
159
|
+
});
|
160
|
+
|
161
|
+
mockMC.getStats.resolves([
|
162
|
+
{type: 'transport', id: 't1'},
|
163
|
+
{type: 'candidate-pair', id: 'cp2', localCandidateId: 'lc2', selected: true},
|
164
|
+
{type: 'local-candidate', id: 'lc2', port: 1234},
|
165
|
+
]);
|
166
|
+
const info = await mediaProperties.getCurrentConnectionInfo();
|
167
|
+
assert.equal(info.ipVersion, 'IPv4');
|
168
|
+
|
169
|
+
assert.calledWith(tsSdpModule.parse, rtcPeerConnection.localDescription.sdp);
|
170
|
+
});
|
171
|
+
|
172
|
+
it('returns ipVersion="IPv6" if candidate from SDP with matching port number has IPv6 address', async () => {
|
173
|
+
sinon.stub(tsSdpModule, 'parse').returns({
|
174
|
+
avMedia: [
|
175
|
+
{
|
176
|
+
iceInfo: {
|
177
|
+
candidates: [
|
178
|
+
{
|
179
|
+
port: 5000,
|
180
|
+
connectionAddress: 'fe80::1ff:fe23:4567:890a',
|
181
|
+
},
|
182
|
+
],
|
183
|
+
},
|
184
|
+
},
|
185
|
+
],
|
186
|
+
});
|
187
|
+
|
188
|
+
mockMC.getStats.resolves([
|
189
|
+
{type: 'transport', id: 't1'},
|
190
|
+
{type: 'candidate-pair', id: 'cp2', localCandidateId: 'lc2', selected: true},
|
191
|
+
{type: 'local-candidate', id: 'lc2', port: 5000},
|
192
|
+
]);
|
193
|
+
const info = await mediaProperties.getCurrentConnectionInfo();
|
194
|
+
assert.equal(info.ipVersion, 'IPv6');
|
195
|
+
|
196
|
+
assert.calledWith(tsSdpModule.parse, rtcPeerConnection.localDescription.sdp);
|
197
|
+
});
|
198
|
+
|
199
|
+
it('returns ipVersion=undefined if parsing of the SDP fails', async () => {
|
200
|
+
sinon.stub(tsSdpModule, 'parse').throws(new Error('fake error'));
|
201
|
+
|
202
|
+
mockMC.getStats.resolves([
|
203
|
+
{type: 'candidate-pair', id: 'cp2', localCandidateId: 'lc2', selected: true},
|
204
|
+
{type: 'local-candidate', id: 'lc2', port: 5000},
|
205
|
+
]);
|
206
|
+
const info = await mediaProperties.getCurrentConnectionInfo();
|
207
|
+
assert.equal(info.ipVersion, undefined);
|
208
|
+
|
209
|
+
assert.calledWith(tsSdpModule.parse, rtcPeerConnection.localDescription.sdp);
|
210
|
+
});
|
211
|
+
});
|
212
|
+
});
|
213
|
+
|
84
214
|
describe('selectedCandidatePairChanges and numTransports', () => {
|
85
215
|
it('returns correct values when getStats() returns no transport stats at all', async () => {
|
86
216
|
mockMC.getStats.resolves([{type: 'something', id: '1234'}]);
|
@@ -110,5 +110,24 @@ describe('plugin-meetings', () => {
|
|
110
110
|
|
111
111
|
assert.isTrue(brbState.state.server.enabled);
|
112
112
|
});
|
113
|
+
|
114
|
+
it('invokes handleServerBrbUpdate with correct client state after syncing with server', async () => {
|
115
|
+
const sendLocalBrbStateToServerStub = sinon
|
116
|
+
.stub(brbState, 'sendLocalBrbStateToServer')
|
117
|
+
.resolves();
|
118
|
+
|
119
|
+
const handleServerBrbUpdateSpy = sinon.spy(brbState, 'handleServerBrbUpdate');
|
120
|
+
|
121
|
+
await brbState.enable(true, meeting.sendSlotManager);
|
122
|
+
|
123
|
+
assert.isTrue(sendLocalBrbStateToServerStub.calledOnce);
|
124
|
+
|
125
|
+
assert.isTrue(handleServerBrbUpdateSpy.calledOnceWith(brbState.state.client.enabled));
|
126
|
+
|
127
|
+
assert.isFalse(brbState.state.syncToServerInProgress);
|
128
|
+
|
129
|
+
sendLocalBrbStateToServerStub.restore();
|
130
|
+
handleServerBrbUpdateSpy.restore();
|
131
|
+
});
|
113
132
|
});
|
114
133
|
});
|
@@ -76,6 +76,8 @@ describe('plugin-meetings', () => {
|
|
76
76
|
canShareDesktop: null,
|
77
77
|
canShareContent: null,
|
78
78
|
canTransferFile: null,
|
79
|
+
canRealtimeCloseCaption: null,
|
80
|
+
canRealtimeCloseCaptionManual: null,
|
79
81
|
canChat: null,
|
80
82
|
canDoVideo: null,
|
81
83
|
canAnnotate: null,
|
@@ -90,10 +92,16 @@ describe('plugin-meetings', () => {
|
|
90
92
|
canShowStageView: null,
|
91
93
|
canEnableStageView: null,
|
92
94
|
canDisableStageView: null,
|
93
|
-
isPracticeSessionOn
|
94
|
-
isPracticeSessionOff
|
95
|
+
isPracticeSessionOn: null,
|
96
|
+
isPracticeSessionOff: null,
|
95
97
|
canStartPracticeSession: null,
|
96
98
|
canStopPracticeSession: null,
|
99
|
+
requiresPostMeetingDataConsentPrompt: null,
|
100
|
+
canEnableAnnotation: null,
|
101
|
+
canDisableAnnotation: null,
|
102
|
+
canEnableRemoteDesktopControl: null,
|
103
|
+
canDisableRemoteDesktopControl: null,
|
104
|
+
canMoveToLobby: null,
|
97
105
|
|
98
106
|
...expected,
|
99
107
|
};
|
@@ -176,6 +184,8 @@ describe('plugin-meetings', () => {
|
|
176
184
|
'canShareDesktop',
|
177
185
|
'canShareContent',
|
178
186
|
'canTransferFile',
|
187
|
+
'canRealtimeCloseCaption',
|
188
|
+
'canRealtimeCloseCaptionManual',
|
179
189
|
'canChat',
|
180
190
|
'canDoVideo',
|
181
191
|
'canAnnotate',
|
@@ -194,8 +204,13 @@ describe('plugin-meetings', () => {
|
|
194
204
|
'isPracticeSessionOff',
|
195
205
|
'canStartPracticeSession',
|
196
206
|
'canStopPracticeSession',
|
197
|
-
|
198
|
-
|
207
|
+
'requiresPostMeetingDataConsentPrompt',
|
208
|
+
'canEnableAnnotation',
|
209
|
+
'canDisableAnnotation',
|
210
|
+
'canEnableRemoteDesktopControl',
|
211
|
+
'canDisableRemoteDesktopControl',
|
212
|
+
'canMoveToLobby',
|
213
|
+
].forEach((key) => {
|
199
214
|
it(`get and set for ${key} work as expected`, () => {
|
200
215
|
const inMeetingActions = new InMeetingActions();
|
201
216
|
|