mediasoup-client 3.6.60 → 3.6.62

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/npm-scripts.js CHANGED
@@ -88,13 +88,16 @@ switch (task)
88
88
  break;
89
89
  }
90
90
 
91
+ case 'release:check':
92
+ {
93
+ checkRelease();
94
+
95
+ break;
96
+ }
97
+
91
98
  case 'release':
92
99
  {
93
- installDeps();
94
- buildTypescript(/* force */ true);
95
- replaceVersion();
96
- lint();
97
- test();
100
+ checkRelease();
98
101
  executeCmd(`git commit -am '${version}'`);
99
102
  executeCmd(`git tag -a ${version} -m '${version}'`);
100
103
  executeCmd(`git push origin v${MAYOR_VERSION}`);
@@ -163,8 +166,7 @@ function lint()
163
166
  {
164
167
  console.log('npm-scripts.js [INFO] lint()');
165
168
 
166
- executeCmd('MEDIASOUP_NODE_LANGUAGE=typescript eslint -c .eslintrc.js --ext=ts src');
167
- executeCmd('MEDIASOUP_NODE_LANGUAGE=javascript eslint -c .eslintrc.js --ext=js --ignore-pattern \'!.eslintrc.js\' .eslintrc.js npm-scripts.js test');
169
+ executeCmd('eslint -c .eslintrc.js --max-warnings 0 src .eslintrc.js npm-scripts.js');
168
170
  }
169
171
 
170
172
  function test()
@@ -184,6 +186,17 @@ function installDeps()
184
186
  executeCmd('npm install --package-lock-only --ignore-scripts');
185
187
  }
186
188
 
189
+ function checkRelease()
190
+ {
191
+ console.log('npm-scripts.js [INFO] checkRelease()');
192
+
193
+ installDeps();
194
+ buildTypescript(/* force */ true);
195
+ replaceVersion();
196
+ lint();
197
+ test();
198
+ }
199
+
187
200
  function executeCmd(command, exitOnError = true)
188
201
  {
189
202
  console.log(`npm-scripts.js [INFO] executeCmd(): ${command}`);
@@ -196,7 +209,13 @@ function executeCmd(command, exitOnError = true)
196
209
  {
197
210
  if (exitOnError)
198
211
  {
212
+ console.error(`npm-scripts.js [ERROR] executeCmd() failed, exiting: ${error}`);
213
+
199
214
  process.exit(1);
200
215
  }
216
+ else
217
+ {
218
+ console.log(`npm-scripts.js [INFO] executeCmd() failed, ignoring: ${error}`);
219
+ }
201
220
  }
202
221
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "mediasoup-client",
3
- "version": "3.6.60",
3
+ "version": "3.6.62",
4
4
  "description": "mediasoup client side JavaScript library",
5
5
  "contributors": [
6
6
  "Iñaki Baz Castillo <ibc@aliax.net> (https://inakibaz.me)",
@@ -39,16 +39,29 @@
39
39
  "test": "node npm-scripts.js test",
40
40
  "coverage": "node npm-scripts.js coverage",
41
41
  "install-deps": "node npm-scripts.js install-deps",
42
+ "release:check": "node npm-scripts.js release:check",
42
43
  "release": "node npm-scripts.js release"
43
44
  },
44
45
  "jest": {
45
46
  "verbose": true,
46
47
  "testEnvironment": "node",
47
- "testRegex": "test/test.*\\.js"
48
+ "testRegex": "src/tests/test.*\\.ts",
49
+ "transform": {
50
+ "^.*\\.ts$": [
51
+ "ts-jest",
52
+ {
53
+ "diagnostics": {
54
+ "ignoreCodes": [
55
+ "TS151001"
56
+ ]
57
+ }
58
+ }
59
+ ]
60
+ },
61
+ "cacheDirectory": ".cache/jest"
48
62
  },
49
63
  "dependencies": {
50
64
  "@types/debug": "^4.1.7",
51
- "@types/events": "^3.0.0",
52
65
  "awaitqueue": "^2.4.0",
53
66
  "bowser": "^2.11.0",
54
67
  "debug": "^4.3.4",
@@ -56,9 +69,12 @@
56
69
  "fake-mediastreamtrack": "^1.1.6",
57
70
  "h264-profile-level-id": "^1.0.1",
58
71
  "sdp-transform": "^2.14.1",
59
- "supports-color": "^9.2.3"
72
+ "supports-color": "^9.2.3",
73
+ "uuid": "^3.4.0"
60
74
  },
61
75
  "devDependencies": {
76
+ "@types/events": "^3.0.0",
77
+ "@types/jest": "^29.2.3",
62
78
  "@types/sdp-transform": "^2.4.5",
63
79
  "@types/uuid": "^3.4.9",
64
80
  "@typescript-eslint/eslint-plugin": "^5.43.0",
@@ -66,10 +82,9 @@
66
82
  "eslint": "^8.27.0",
67
83
  "eslint-plugin-jest": "^27.1.5",
68
84
  "jest": "^29.3.1",
69
- "jest-tobetype": "^1.2.3",
70
85
  "open-cli": "^7.1.0",
86
+ "ts-jest": "^29.0.3",
71
87
  "tsc-watch": "^5.0.3",
72
- "typescript": "^4.9.3",
73
- "uuid": "^3.4.0"
88
+ "typescript": "^4.9.3"
74
89
  }
75
90
  }