@webex/media-helpers 3.0.0-next.12 → 3.0.0-next.14
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/package.json
CHANGED
|
@@ -23,7 +23,7 @@
|
|
|
23
23
|
"deploy:npm": "yarn npm publish"
|
|
24
24
|
},
|
|
25
25
|
"dependencies": {
|
|
26
|
-
"@webex/internal-media-core": "2.2.
|
|
26
|
+
"@webex/internal-media-core": "2.2.3",
|
|
27
27
|
"@webex/ts-events": "^1.1.0",
|
|
28
28
|
"@webex/web-media-effects": "^2.15.6"
|
|
29
29
|
},
|
|
@@ -39,10 +39,10 @@
|
|
|
39
39
|
"@webex/eslint-config-legacy": "^0.0.0",
|
|
40
40
|
"@webex/jest-config-legacy": "^0.0.0",
|
|
41
41
|
"@webex/legacy-tools": "^0.0.0",
|
|
42
|
-
"@webex/test-helper-chai": "^2.60.0-next.
|
|
43
|
-
"@webex/test-helper-mock-webex": "^2.60.0-next.
|
|
42
|
+
"@webex/test-helper-chai": "^2.60.0-next.3",
|
|
43
|
+
"@webex/test-helper-mock-webex": "^2.60.0-next.3",
|
|
44
44
|
"eslint": "^8.24.0",
|
|
45
45
|
"sinon": "^9.2.4"
|
|
46
46
|
},
|
|
47
|
-
"version": "3.0.0-next.
|
|
47
|
+
"version": "3.0.0-next.14"
|
|
48
48
|
}
|
|
@@ -41,6 +41,7 @@ describe('media-helpers', () => {
|
|
|
41
41
|
label: 'fake track',
|
|
42
42
|
id: 'fake track id',
|
|
43
43
|
enabled: true,
|
|
44
|
+
muted: false,
|
|
44
45
|
addEventListener: sinon.stub(),
|
|
45
46
|
},
|
|
46
47
|
]),
|
|
@@ -73,22 +74,22 @@ describe('media-helpers', () => {
|
|
|
73
74
|
|
|
74
75
|
it('returns a reasonable length string from JSON.stringify()', () => {
|
|
75
76
|
assert.isBelow(JSON.stringify(stream).length, 200);
|
|
76
|
-
})
|
|
77
|
+
});
|
|
77
78
|
|
|
78
79
|
describe('#setServerMuted', () => {
|
|
79
80
|
afterEach(() => {
|
|
80
81
|
sinon.restore();
|
|
81
82
|
});
|
|
82
83
|
|
|
83
|
-
const checkSetServerMuted =
|
|
84
|
-
|
|
84
|
+
const checkSetServerMuted = (startMute, setMute, expectedCalled) => {
|
|
85
|
+
stream.setMuted(startMute);
|
|
85
86
|
|
|
86
87
|
assert.equal(stream.muted, startMute);
|
|
87
88
|
|
|
88
89
|
const handler = sinon.fake();
|
|
89
90
|
stream.on(event.ServerMuted, handler);
|
|
90
91
|
|
|
91
|
-
|
|
92
|
+
stream.setServerMuted(setMute, 'remotelyMuted');
|
|
92
93
|
|
|
93
94
|
assert.equal(stream.muted, setMute);
|
|
94
95
|
if (expectedCalled) {
|
|
@@ -99,19 +100,19 @@ describe('media-helpers', () => {
|
|
|
99
100
|
};
|
|
100
101
|
|
|
101
102
|
it('tests true to false', async () => {
|
|
102
|
-
|
|
103
|
+
checkSetServerMuted(true, false, true);
|
|
103
104
|
});
|
|
104
105
|
|
|
105
106
|
it('tests false to true', async () => {
|
|
106
|
-
|
|
107
|
+
checkSetServerMuted(false, true, true);
|
|
107
108
|
});
|
|
108
109
|
|
|
109
110
|
it('tests true to true', async () => {
|
|
110
|
-
|
|
111
|
+
checkSetServerMuted(true, true, false);
|
|
111
112
|
});
|
|
112
113
|
|
|
113
114
|
it('tests false to false', async () => {
|
|
114
|
-
|
|
115
|
+
checkSetServerMuted(false, false, false);
|
|
115
116
|
});
|
|
116
117
|
});
|
|
117
118
|
|
|
@@ -137,7 +138,7 @@ describe('media-helpers', () => {
|
|
|
137
138
|
assert.calledOnceWithExactly(spy, LocalDisplayStream);
|
|
138
139
|
});
|
|
139
140
|
});
|
|
140
|
-
|
|
141
|
+
|
|
141
142
|
describe('createDisplayStreamWithAudio', () => {
|
|
142
143
|
it('checks createDisplayStreamWithAudio', async () => {
|
|
143
144
|
const spy = sinon.stub(wcmestreams, 'createDisplayStreamWithAudio').returns('something');
|